@@ -16,15 +16,15 @@ jobs:
16
16
# Steps represent a sequence of tasks that will be executed as part of the job
17
17
steps :
18
18
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
19
- - uses : actions/checkout@v2
19
+ - uses : actions/checkout@v3
20
20
21
- - uses : actions/setup-java@v2
21
+ - uses : actions/setup-java@v3
22
22
with :
23
23
distribution : zulu
24
24
java-version : 17
25
25
26
26
- name : Setup Gradle
27
- uses : gradle/gradle-build-action@v2
27
+ uses : gradle/gradle-build-action@v3
28
28
29
29
# Compile code
30
30
- name : Compile code
@@ -55,12 +55,12 @@ jobs:
55
55
56
56
# Steps represent a sequence of tasks that will be executed as part of the job
57
57
steps :
58
- - uses : actions/checkout@v2
58
+ - uses : actions/checkout@v3
59
59
60
60
# Add Docker labels and tags
61
61
- name : Docker meta
62
62
id : docker_meta
63
- uses : crazy-max/ghaction-docker-meta@v2
63
+ uses : docker/metadata-action@v4
64
64
with :
65
65
images : ${{ env.DOCKER_IMAGE }}
66
66
# output 2.1.2, 2.1 and 2
@@ -70,23 +70,22 @@ jobs:
70
70
71
71
# Setup docker build environment
72
72
- name : Set up QEMU
73
- uses : docker/setup-qemu-action@v1
73
+ uses : docker/setup-qemu-action@v2
74
74
- name : Set up Docker Buildx
75
- uses : docker/setup-buildx-action@v1
75
+ uses : docker/setup-buildx-action@v2
76
76
77
77
- name : Login to DockerHub
78
- uses : docker/login-action@v1
78
+ uses : docker/login-action@v2
79
79
with :
80
80
username : ${{ secrets.DOCKERHUB_USERNAME }}
81
81
password : ${{ secrets.DOCKERHUB_TOKEN }}
82
82
83
83
- name : Build and push
84
84
id : docker_build
85
- uses : docker/build-push-action@v2
85
+ uses : docker/build-push-action@v3
86
86
with :
87
- context : ./
87
+ context : .
88
88
file : ./Dockerfile
89
- # Allow running the image on the architectures supported by openjdk:11-jre-slim
90
89
platforms : linux/amd64,linux/arm64
91
90
push : true
92
91
tags : ${{ steps.docker_meta.outputs.tags }}
98
97
org.opencontainers.image.vendor=RADAR-base
99
98
org.opencontainers.image.licenses=Apache-2.0
100
99
100
+ - name : Build locally
101
+ id : docker_build
102
+ uses : docker/build-push-action@v3
103
+ with :
104
+ context : .
105
+ file : ./Dockerfile
106
+ platforms : linux/amd64
107
+ load : true
108
+ tags : ${{ steps.docker_meta.outputs.tags }}
109
+
101
110
- name : Inspect image
102
111
run : |
103
- docker pull ${{ env.DOCKER_IMAGE }}:${{ steps.docker_meta.outputs.version }}
104
112
docker image inspect ${{ env.DOCKER_IMAGE }}:${{ steps.docker_meta.outputs.version }}
113
+ docker run --rm ${{ env.DOCKER_IMAGE }}:${{ steps.docker_meta.outputs.version }} --help
0 commit comments