generated from wearefrank/skeleton
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
51 lines (37 loc) · 2.01 KB
/
Dockerfile
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
ARG FF_VERSION=8.3.0-20241003.042327
FROM frankframework/frankframework:${FF_VERSION} as ff-base
## Uncomment this section if the Frank! contains custom classes.
# Copy dependencies
COPY --chown=tomcat lib/server/ /usr/local/tomcat/lib/
COPY --chown=tomcat lib/webapp/ /usr/local/tomcat/webapps/ROOT/WEB-INF/lib/
# Compile custom class
FROM eclipse-temurin:17-jdk-jammy AS custom-code-builder
# # Uncomment this section if the Frank! contains custom classes.
# # Copy dependencies
# COPY --from=ff-base /usr/local/tomcat/lib/ /usr/local/tomcat/lib/
# COPY --from=ff-base /usr/local/tomcat/webapps/ROOT /usr/local/tomcat/webapps/ROOT
# # Copy custom class
# COPY src/main/java /tmp/java
# RUN mkdir /tmp/classes && \
# javac \
# /tmp/java/org/<path-to-customcode-file>.java \
# -classpath "/usr/local/tomcat/webapps/ROOT/WEB-INF/lib/*:/usr/local/tomcat/lib/*" \
# -verbose -d /tmp/classes
FROM ff-base
# Copy database connection settings
COPY --chown=tomcat src/main/webapp/META-INF/context.xml /usr/local/tomcat/conf/Catalina/localhost/ROOT.xml
# Copy Frank!
COPY --chown=tomcat src/main/configurations/ /opt/frank/configurations/
COPY --chown=tomcat src/main/resources/ /opt/frank/resources/
COPY --chown=tomcat src/main/secrets/ /opt/frank/secrets/
COPY --chown=tomcat src/test/testtool/ /opt/frank/testtool/
ENV credentialFactory.class=nl.nn.credentialprovider.PropertyFileCredentialFactory
ENV credentialFactory.map.properties=/opt/frank/secrets/credentials.properties
# # Uncomment this section if the Frank! contains custom classes.
# # Copy compiled custom classes
# COPY --from=custom-code-builder --chown=tomcat /tmp/classes/ /usr/local/tomcat/webapps/ROOT/WEB-INF/classes
# COPY --chown=tomcat entrypoint.sh /scripts/entrypoint.sh
HEALTHCHECK --interval=15s --timeout=5s --start-period=30s --retries=60 \
CMD curl --fail --silent http://localhost:8080/iaf/api/server/health || (curl --silent http://localhost:8080/iaf/api/server/health && exit 1)
# ENTRYPOINT ["/scripts/entrypoint.sh"]
# CMD ["catalina.sh", "run"]