Skip to content

Commit 78ab963

Browse files
committed
docker build when releasing
1 parent 01bc9d1 commit 78ab963

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/release.yml

+23
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,29 @@ name: Release
55
jobs:
66
test:
77
uses: remotemobprogramming/timer/.github/workflows/test.yml@main
8+
dockerbuild:
9+
needs: test
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v3
13+
- name: Setup Java JDK
14+
uses: actions/[email protected]
15+
with:
16+
distribution: 'zulu'
17+
java-version: '21'
18+
- name: Login to DockerHub
19+
uses: docker/login-action@v2
20+
with:
21+
username: ${{ secrets.DOCKERHUB_USERNAME }}
22+
password: ${{ secrets.DOCKERHUB_TOKEN }}
23+
- name: Docker Build
24+
run: ./mvnw spring-boot:build-image
25+
- name: Docker Tag
26+
run: docker tag remotemobprogramming/mob-timer remotemobprogramming/mob-timer:${{ github.sha }}
27+
- name: Docker Push Latest
28+
run: docker push remotemobprogramming/mob-timer:latest
29+
- name: Docker Push Tag
30+
run: docker push remotemobprogramming/mob-timer:${{ github.sha }}
831
deployment:
932
needs: test
1033
environment: production

0 commit comments

Comments
 (0)