Skip to content

added dockerfile

added dockerfile #9

Workflow file for this run

# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
name: Build Docker Images
on:
push:
branches: [main]
paths:
- 'docker/**'
- '.github/workflows/docker-base.yml'
- 'conda/*.yml'
- 'pyproject.toml'
pull_request:
branches: [main]
paths:
- 'docker/**'
- '.github/workflows/docker-base.yml'
- 'conda/*.yml'
- 'pyproject.toml'
release:
types: [published]
jobs:
build_base:
strategy:
matrix:
RAPIDS_VER:
- 24.04
name: Build Base Docker image
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
attestations: write
steps:
- name: Maximize build disk space
uses: easimon/maximize-build-space@v10
with:
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
root-reserve-mb: 35840
- name: Check out the repo
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: |
ghcr.io/${{ github.repository }}-deps
- name: create yaml file for conda environment
run: |
grep -v -- '- rapids-singlecell' conda/rsc_rapids_${{ matrix.RAPIDS_VER }}.yml > docker/rsc_rapids.yml
shell: bash
- name: Build and push Docker images
id: push
uses: docker/build-push-action@v5
with:
context: ./docker/
file: ./docker/Dockerfile.deps
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=registry,ref=user/app:latest
- name: Generate artifact attestation
uses: actions/attest-build-provenance@v1
with:
subject-name: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME}}
subject-digest: ${{ steps.push.outputs.digest }}
push-to-registry: true