-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathDockerfile_tiger-zion
52 lines (42 loc) · 1.68 KB
/
Dockerfile_tiger-zion
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
# Copyright (c) 2023 gematik - Gesellschaft für Telematikanwendungen der Gesundheitskarte mbH
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# Docker Rules from https://wiki.gematik.de/display/DEV/Docker+Rules
FROM eclipse-temurin:17-jre-alpine
ARG APP=unknown
ARG COMMIT_HASH
ARG VERSION
LABEL de.gematik.vendor="gematik GmbH" \
maintainer="[email protected]" \
de.gematik.app="tiger-$APP" \
de.gematik.git-repo-name="https://gitlab.prod.ccs.gematik.solutions/git/Testtools/tiger/tiger" \
de.gematik.commit-sha=$COMMIT_HASH \
de.gematik.version=$VERSION
# Default USERID and GROUPID
ARG USERID=10000
ARG GROUPID=10000
# Run as User (not root)
USER $USERID:$GROUPID
ENV MANAGEMENT_SERVER_PORT=8081
HEALTHCHECK --interval=1s \
--timeout=1s \
--start-period=1s \
--retries=100 \
CMD wget -T5 -qO- -Y off http://localhost:${MANAGEMENT_SERVER_PORT}/actuator/health | grep UP || exit 1
# Copy the resource to the destination folder and assign permissions
COPY --chown=$USERID:$GROUPID $APP/target/*docker.jar /app/app.jar
# Default Working directory
WORKDIR /app
# Command to be executed.
ENTRYPOINT ["java", "-jar", "app.jar"]