-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (49 loc) · 2.13 KB
/
docker-image.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: Docker Image CI
on:
push:
tags:
- "v*"
# on:
# pull_request:
# branches:
# - main
# types:
# - closed
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build Frontend Image
run: docker build -t deretz/endurace_reporting:frontend.${{ github.ref_name }} -f front/Dockerfile front/
- name: Build Backend Image
run: docker build -t deretz/endurace_reporting:backend.${{ github.ref_name }} -f back/Dockerfile back/
- name: Build GO Image
run: docker build -t deretz/endurace_reporting:go_server.${{ github.ref_name }} -f Dockerfile.go_server .
- name: Build goose Image
run: docker build -t deretz/endurace_reporting:goose.${{ github.ref_name }} -f Dockerfile.goose .
- name: Push Frontend Image
run: |
docker tag deretz/endurace_reporting:frontend.${{ github.ref_name }} deretz/endurace_reporting:frontend.latest
docker push deretz/endurace_reporting:frontend.${{ github.ref_name }}
docker push deretz/endurace_reporting:frontend.latest
- name: Push Backend Image
run: |
docker tag deretz/endurace_reporting:backend.${{ github.ref_name }} deretz/endurace_reporting:backend.latest
docker push deretz/endurace_reporting:backend.${{ github.ref_name }}
docker push deretz/endurace_reporting:backend.latest
- name: Push GO Image
run: |
docker tag deretz/endurace_reporting:go_server.${{ github.ref_name }} deretz/endurace_reporting:go_server.latest
docker push deretz/endurace_reporting:go_server.${{ github.ref_name }}
docker push deretz/endurace_reporting:go_server.latest
- name: Push goose Image
run: |
docker tag deretz/endurace_reporting:goose.${{ github.ref_name }} deretz/endurace_reporting:goose.latest
docker push deretz/endurace_reporting:goose.${{ github.ref_name }}
docker push deretz/endurace_reporting:goose.latest