add results figures, tables and docker image #7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "build" | |
on: | |
push: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- 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: Install Nextflow | |
uses: stracquadaniolab/[email protected] | |
- name: Cache Nextflow dependencies | |
uses: actions/cache@v2 | |
with: | |
path: ${{ env.HOME }}/.nextflow | |
key: ${{ runner.os }}-nextflow-${{ hashFiles('nextflow.config') }} | |
restore-keys: | | |
${{ runner.os }}-nextflow- | |
- name: Test Nextflow pipeline | |
run: | | |
chmod +x bin/* | |
nextflow run . -profile test,ci,docker | |
- name: Push image to GitHub Container Registry | |
if: startsWith(github.event.ref, 'refs/tags') | |
uses: docker/build-push-action@v2 | |
with: | |
context: . | |
file: containers/Dockerfile | |
platforms: linux/amd64 | |
push: true | |
tags: | | |
ghcr.io/${{ github.repository }}:v0.0.10, ghcr.io/${{ github.repository }}:latest |