Skip to content

Commit f957d10

Browse files
committed
Switch to Docker Hub registery and build also x86 Docker image
1 parent e39046f commit f957d10

File tree

4 files changed

+46
-5
lines changed

4 files changed

+46
-5
lines changed

.github/workflows/deploy.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,8 @@ jobs:
2121
- name: Docker Login
2222
uses: docker/login-action@v2
2323
with:
24-
registry: ghcr.io
2524
username: ${{ github.actor }}
26-
password: ${{ secrets.GHCR_TOKEN }}
25+
password: ${{ secrets.DOCKER_HUB_TOKEN }}
2726

2827
- uses: actions/setup-java@v4
2928
with:
@@ -40,4 +39,4 @@ jobs:
4039
run: mvn spring-boot:build-image -DskipTests
4140

4241
- name: Push Docker image
43-
run: docker push ghcr.io/tutorialwork/kleinanzeigen-ads-renewer:${{ env.VERSION }}
42+
run: docker push tutorialwork/kleinanzeigen-ads-renewer:${{ env.VERSION }}

.github/workflows/deploy_x86.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Deploy x86 Docker Image
2+
3+
on:
4+
workflow_run:
5+
workflows:
6+
- 'Bump version'
7+
types:
8+
- completed
9+
10+
jobs:
11+
build_and_push:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v4
17+
18+
- name: Set up Docker Buildx
19+
uses: docker/setup-buildx-action@v2
20+
21+
- name: Docker Login
22+
uses: docker/login-action@v2
23+
with:
24+
username: ${{ github.actor }}
25+
password: ${{ secrets.DOCKER_HUB_TOKEN }}
26+
27+
- uses: actions/setup-java@v4
28+
with:
29+
distribution: 'liberica'
30+
java-version: '21'
31+
32+
- name: Get Maven version
33+
run: |
34+
VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
35+
echo "Project Maven Version: $VERSION"
36+
echo "VERSION=$VERSION" >> $GITHUB_ENV
37+
38+
- name: Build with Maven
39+
run: mvn spring-boot:build-image -DskipTests
40+
41+
- name: Push Docker image
42+
run: docker push tutorialwork/kleinanzeigen-ads-renewer:${{ env.VERSION }}

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ The host name for iCloud is: ``imap.mail.me.com``
3838
```yaml
3939
services:
4040
app:
41-
image: ghcr.io/tutorialwork/kleinanzeigen-ads-renewer:1.0.1
41+
image: tutorialwork/kleinanzeigen-ads-renewer:1.2.0
4242
environment:
4343
- IMAP_SERVERS_GMAIL_HOST=imap.gmail.com
4444
- IMAP_SERVERS_GMAIL_USERNAME=YOUR_GMAIL_EMAIL

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@
8686
<artifactId>spring-boot-maven-plugin</artifactId>
8787
<configuration>
8888
<image>
89-
<name>ghcr.io/tutorialwork/kleinanzeigen-ads-renewer:${project.version}</name>
89+
<name>tutorialwork/kleinanzeigen-ads-renewer:${project.version}</name>
9090
<buildpacks>
9191
<buildpack>paketobuildpacks/java</buildpack>
9292
</buildpacks>

0 commit comments

Comments
 (0)