-
Notifications
You must be signed in to change notification settings - Fork 2
50 lines (44 loc) · 1.58 KB
/
build-docker-kallisto-bustools.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
name: IGVF kallisto-bustools CI
on:
push:
branches: [ "dev", "main" ]
paths:
- 'modules/igvf-kallisto-bustools/**'
pull_request:
branches: [ "dev", "main" ]
paths:
- 'modules/igvf-kallisto-bustools/**'
workflow_dispatch:
inputs:
image_tag:
description: 'Docker Image Tag (default: branch_name)'
env:
PROJECT_NAME: IGVF atomic workflows CI
# Github repo name
REPOSITORY_NAME: ${{ github.event.repository.name }}
# Region-specific Google Docker repository where GOOGLE_PROJECT/REPOSITORY_NAME can be found
DOCKER_REGISTRY: docker.io
DOCKER_PATH: igvf/kallisto-bustools
TAG: ${{ github.event.inputs.image_tag || github.head_ref || github.ref_name }}
jobs:
build-and-test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: modules/igvf-kallisto-bustools
steps:
- uses: actions/checkout@v4
- name: Check out the repository
run: |
echo "Checking out the repository"
pwd
ls -lht
- name: log in to DockerHub
run: ${{ secrets.DOCKER_LOGIN_CMD }}
- name: Build the Docker image
run: docker build . --file docker_builder.dockerfile --tag ${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_PATH }}:${{ env.TAG }}
# - name: Run tests in Docker container
# run: |
# docker run --init --rm -v ${{ github.workspace }}/test_data:/software/test_data ${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_PATH }}:${{ env.TAG }} pytest /software/tests/test_run_kallisto.py
- name: Push image
run: docker push ${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_PATH }}:${{ env.TAG }}