Skip to content

Commit

Permalink
update CI
Browse files Browse the repository at this point in the history
  • Loading branch information
essharom committed Aug 21, 2024
1 parent 9d17302 commit 0ce141b
Showing 1 changed file with 6 additions and 26 deletions.
32 changes: 6 additions & 26 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,38 +10,15 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up QEMU
uses: docker/setup-qemu-action@v1

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1

- name: Login to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GHCR_TOKEN }}

- name: Cache Docker layers
uses: actions/cache@v2
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-docker-${{ hashFiles('containers/Dockerfile') }}
restore-keys: |
${{ runner.os }}-docker-
- name: Build Docker image
uses: docker/build-push-action@v2
with:
context: .
file: containers/Dockerfile
platforms: linux/amd64
cache-from: type=local,src=/tmp/.buildx-cache
load: true
push: false
tags: |
ghcr.io/${{ github.repository }}:v0.0.10, ghcr.io/${{ github.repository }}:latest
- name: Pull pre-built Docker image
run: docker pull ghcr.io/${{ github.repository }}:latest

- name: Install Nextflow
uses: stracquadaniolab/[email protected]
Expand All @@ -56,7 +33,10 @@ jobs:
- name: Test Nextflow pipeline
run: |
chmod +x bin/*
docker run --rm \
-v ${{ github.workspace }}:/workspace \
-w /workspace \
ghcr.io/${{ github.repository }}:latest \
nextflow run . -profile test,ci,docker
- name: Push image to GitHub Container Registry
Expand Down

0 comments on commit 0ce141b

Please sign in to comment.