Skip to content
Open
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
8 changes: 4 additions & 4 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,23 +22,23 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Log in to the Container registry
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
uses: docker/login-action@v3.3.0
with:
registry: ${{ env.REGISTRY }}
username: nipreps-bot
password: ${{ secrets.NIPREPS_BOT_PACKAGES }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
uses: docker/metadata-action@v5.6.1
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}

- name: Build and push Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
uses: docker/build-push-action@v6.13.0
with:
context: .
push: true
Expand Down
16 changes: 9 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,15 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

FROM python:3.11-alpine as builder
FROM python:3.12-alpine AS builder

RUN apk update && apk add --no-cache curl bzip2 gcc libffi-dev musl-dev
RUN apk add --no-cache curl bzip2 gcc libffi-dev musl-dev
RUN pip install --no-cache-dir virtualenv
RUN virtualenv /opt/venv && source /opt/venv/bin/activate && \
python -m pip install --no-cache-dir datalad pytest ssh_agent_setup

RUN python -m pip install --no-cache-dir datalad pytest ssh_agent_setup
FROM python:3.12-alpine
RUN apk add --no-cache git openssh-client git-annex
COPY --from=builder /opt/venv /opt/venv

FROM python:3.11-alpine
COPY --from=builder /usr/local /usr/local

RUN apk update && apk add --no-cache git openssh-client git-annex
ENV PATH=$PATH:/opt/venv/bin