Skip to content

Commit

Permalink
Install Singularity 3 from official DEB
Browse files Browse the repository at this point in the history
  • Loading branch information
bpoldrack committed Dec 9, 2022
1 parent 2776e72 commit 5abd9f6
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ environment:
- ID: Ubu20
DTS: datalad_container
APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu2004
INSTALL_SYSPKGS: python3-virtualenv xz-utils singularity-container
INSTALL_SYSPKGS: python3-virtualenv xz-utils jq
# system git-annex is way too old, use better one
INSTALL_GITANNEX: git-annex -m deb-url --url http://snapshot.debian.org/archive/debian/20210906T204127Z/pool/main/g/git-annex/git-annex_8.20210903-1_amd64.deb
CODECOV_BINARY: https://uploader.codecov.io/latest/linux/codecov
Expand Down Expand Up @@ -158,6 +158,8 @@ install:
- sh: "[ \"$ID\"x = \"Ubu20x\" ] && wget -O- http://neuro.debian.net/lists/focal.us-nh.full | sudo tee /etc/apt/sources.list.d/neurodebian.sources.list && ( sudo apt-key adv --recv-keys --keyserver hkps://keyserver.ubuntu.com 0xA5D32F012649A5A9 || { wget -q -O- http://neuro.debian.net/_static/neuro.debian.net.asc | sudo apt-key add -; } )"
# Missing system software
- sh: "[ -n \"$INSTALL_SYSPKGS\" ] && ( [ \"x${APPVEYOR_BUILD_WORKER_IMAGE}\" = \"xmacOS\" ] && brew install -q ${INSTALL_SYSPKGS} || { sudo apt-get update -y -qq && sudo apt-get install -qq --no-install-recommends -y ${INSTALL_SYSPKGS}; } ) || true"
# Install singularity
- sh: tools/ci/install-singularity.sh
# Install git-annex on windows, otherwise INSTALL_SYSPKGS can be used
# deploy git-annex, if desired
- cmd: IF DEFINED INSTALL_GITANNEX datalad-installer --sudo ok %INSTALL_GITANNEX%
Expand Down
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,9 @@ before_install:
# no recommends to avoid inheriting the entire multimedia stack
- travis_retry sudo eatmydata apt-get install --no-install-recommends git-annex-standalone aria2 git-remote-gcrypt lsof gnupg nocache
# chroot/container stuff
- travis_retry sudo eatmydata apt-get install xz-utils singularity-container
- travis_retry sudo eatmydata apt-get install xz-utils jq
- pip install --upgrade pip
- tools/ci/install-singularity.sh


install:
Expand Down
8 changes: 8 additions & 0 deletions tools/ci/install-singularity.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash

release="$(curl -fsSL https://api.github.com/repos/sylabs/singularity/releases/latest | jq -r .tag_name)"
codename="$(lsb_release -cs)"
arch="$(dpkg --print-architecture)"
wget -O /tmp/singularity-ce.deb https://github.com/sylabs/singularity/releases/download/$release/singularity-ce_${release#v}-${codename}_$arch.deb
sudo dpkg -i /tmp/singularity-ce.deb
sudo apt-get install -f

0 comments on commit 5abd9f6

Please sign in to comment.