-
Notifications
You must be signed in to change notification settings - Fork 0
34 lines (29 loc) · 1.01 KB
/
build.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
name: build
on: [push]
env:
TAG_GHCR: mrc-ide/wodin
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- id: ci-env
uses: ./.github/actions/ci-env-and-ghcr-login
with:
ghcr-username: ${{ github.actor }}
ghcr-password: ${{ secrets.GITHUB_TOKEN }}
- name: Checking
run: |
curl 'https://ghcr.io/v2/mrc-ide/wodin/manifests/mrc-5976' -H 'accept: application/vnd.docker.distribution.manifest.v2+json' -H 'Authorization:Bearer ${{ secrets.GITHUB_TOKEN }}'
- name: Build and push docker
uses: docker/build-push-action@v5
with:
file: ./docker/Dockerfile
push: true
tags: |
ghcr.io/${{env.TAG_GHCR}}:${{steps.ci-env.outputs.CI_SHA}}
ghcr.io/${{env.TAG_GHCR}}:${{steps.ci-env.outputs.CI_BRANCH}}
- name: Smoke test
run: |
./scripts/run-version.sh --app ${{steps.ci-env.outputs.CI_BRANCH}} &
./scripts/smoke-test.sh