-
Notifications
You must be signed in to change notification settings - Fork 5
35 lines (30 loc) · 1.13 KB
/
docker-images.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
name: Docker-Images
on:
push:
branches:
- master
env:
IMG_PREFIX: mayflower/covid19-teststation-termine
jobs:
build_server:
runs-on: ubuntu-latest
if: secrets.docker_hub_token != ''
steps:
- uses: actions/checkout@v2
- name: Build the server Docker image
run: DOCKER_BUILDKIT=1 docker build . --progress=plain --file Dockerfile --target=server --tag $IMG_PREFIX-server:$GITHUB_SHA
- name: Push the server Docker image
env:
DOCKER_HUB_TOKEN: ${{ secrets.docker_hub_token }}
run: docker login -u leux -p $DOCKER_HUB_TOKEN && docker push $IMG_PREFIX-server:$GITHUB_SHA
build_command:
runs-on: ubuntu-latest
if: secrets.docker_hub_token != ''
steps:
- uses: actions/checkout@v2
- name: Build the commands Docker image
run: DOCKER_BUILDKIT=1 docker build . --progress=plain --file Dockerfile --target=command --tag $IMG_PREFIX-command:$GITHUB_SHA
- name: Push the commands Docker image
env:
DOCKER_HUB_TOKEN: ${{ secrets.docker_hub_token }}
run: docker login -u leux -p $DOCKER_HUB_TOKEN && docker push $IMG_PREFIX-command:$GITHUB_SHA