Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-enable Datalad SSH tests on macOS #55

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/build-macos.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -380,10 +380,33 @@ jobs:
hdiutil detach /Volumes/git-annex/
echo /Applications/git-annex.app/Contents/MacOS >> "$GITHUB_PATH"

- name: Set up SSH target
shell: bash
run: |
# coreutils provides a readlink that supports `-f`
brew install coreutils docker docker-machine

# <https://github.com/actions/virtual-environments/issues/4431>
brew uninstall virtualbox
cd "$(brew --repo homebrew/cask)"
git checkout 8670a72380c57c606d6582b645421e31dad2eee2
brew install --cask virtualbox

mkdir -p ~/.docker/machine/cache
wget -O ~/.docker/machine/cache/boot2docker.iso https://github.com/boot2docker/boot2docker/releases/download/v19.03.12/boot2docker.iso
docker-machine --native-ssh create --driver virtualbox default
eval "$(docker-machine env default)"
export PATH="/usr/local/opt/coreutils/libexec/gnubin:$PATH"
curl -fSsL \
https://raw.githubusercontent.com/datalad/datalad/master/tools/ci/prep-travis-forssh.sh \
| bash
echo DATALAD_TESTS_SSH=1 >> "$GITHUB_ENV"

- name: Set up environment
run: |
brew install exempi # Needed by python-xmp-toolkit
mkdir -p /private/tmp/DLTMP
echo TMPDIR=/private/tmp/DLTMP >> "$GITHUB_ENV"
git config --global user.email "[email protected]"
git config --global user.name "GitHub Almighty"

Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/build-ubuntu.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ jobs:
sudo apt-get update -qq
sudo apt-get install eatmydata
sudo eatmydata apt-get install singularity-container gnupg moreutils strace
echo "just a touch to trigger workflow"

- name: Determine git-annex ref to build
run: |
Expand Down Expand Up @@ -416,7 +415,6 @@ jobs:
| bash
echo DATALAD_TESTS_SSH=1 >> "$GITHUB_ENV"


- name: Set up environment
run: |
git config --global user.email "[email protected]"
Expand Down
20 changes: 14 additions & 6 deletions .github/workflows/template/build-{{ostype}}.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -598,25 +598,31 @@ jobs:
{{step}}
{% endfor %}

{% if ostype == "ubuntu" %}
{# TODO: return for macos! https://github.com/datalad/git-annex/issues/42
{% if ostype == "ubuntu" or ostype == "macos" %} #}
{% if ostype == "ubuntu" or ostype == "macos" %}
- name: Set up SSH target
shell: bash
run: |
{% if ostype == "macos" %}
# coreutils provides a readlink that supports `-f`
brew install coreutils docker docker-machine
docker-machine --github-api-token="${{ secrets.GITHUB_TOKEN }}" create --driver virtualbox default

# <https://github.com/actions/virtual-environments/issues/4431>
brew uninstall virtualbox
cd "$(brew --repo homebrew/cask)"
git checkout 8670a72380c57c606d6582b645421e31dad2eee2
brew install --cask virtualbox

mkdir -p ~/.docker/machine/cache
wget -O ~/.docker/machine/cache/boot2docker.iso https://github.com/boot2docker/boot2docker/releases/download/v19.03.12/boot2docker.iso
docker-machine --native-ssh create --driver virtualbox default
eval "$(docker-machine env default)"
export PATH="/usr/local/opt/coreutils/libexec/gnubin:$PATH"
{% endif %}
curl -fSsL \
https://raw.githubusercontent.com/datalad/datalad/master/tools/ci/prep-travis-forssh.sh \
| bash
echo DATALAD_TESTS_SSH=1 >> "$GITHUB_ENV"

{% elif ostype == "windows" %}
{% elif ostype == "windows" %}
- name: Define test host alias
shell: cmd
run: |
Expand Down Expand Up @@ -675,6 +681,8 @@ jobs:
run: |
{% if ostype == "macos" %}
brew install exempi # Needed by python-xmp-toolkit
mkdir -p /private/tmp/DLTMP
echo TMPDIR=/private/tmp/DLTMP >> "$GITHUB_ENV"
{% endif %}
git config --global user.email "[email protected]"
git config --global user.name "GitHub Almighty"
Expand Down