Skip to content

Commit 41d9850

Browse files
committed
docker: more build file cleanup
1 parent d412c3d commit 41d9850

File tree

2 files changed

+8
-10
lines changed

2 files changed

+8
-10
lines changed

docker/base/Dockerfile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,14 @@ COPY launchTomcat.sh \
3939
start-examples.txt \
4040
setupSharedCacheJars.sh /usr/local/tomcat/
4141

42-
# Make directories, make scripts executable, save old tomcat config files
42+
# Make directories, make scripts executable, save old tomcat config files, remove unwanted apps
4343
RUN chmod +x /usr/local/tomcat/launchTomcat.sh /usr/local/tomcat/setupSharedCacheJars.sh; \
4444
mv /usr/local/tomcat/conf/context.xml /usr/local/tomcat/conf/context.xml.bak; \
4545
mv /usr/local/tomcat/conf/tomcat-users.xml /usr/local/tomcat/conf/tomcat-users.xml.bak; \
46+
rm -rf /usr/local/tomcat/webapps/examples \
47+
/usr/local/tomcat/webapps/docs \
48+
/usr/local/tomcat/webapps/host-manager \
49+
/usr/local/tomcat/webapps/ROOT; \
4650
mkdir -p ${SERVER_CONFIG_DIR}; \
4751
mkdir -p ${FIREFLY_WORK_DIR}; \
4852
mkdir -p ${EXTERNAL_MOUNT_POINT}
@@ -73,14 +77,14 @@ EXPOSE 8080 5050 9050 7011
7377
# MIN_JVM_SIZE and MAX_JVM_SIZE should be used to set the min and max JVM side
7478
# at least MAX_JVM_SIZE should almost alway be used on the command line with
7579
# parameter such as: -e "MAX_JVM_SIZE=4G"
76-
ENV MIN_JVM_SIZE=1g
80+
ENV MIN_JVM_SIZE=1G
7781
ENV MAX_JVM_SIZE=8G
7882

7983

8084
#User name and password to use admin
8185
ENV ADMIN_USER=admin
8286
ENV ADMIN_PASSWORD=replaceMe
83-
ENV DEBUG=true
87+
ENV DEBUG=false
8488
ENV MANAGER=true
8589

8690
# if jvmRoute is not passed the hostname (the container id) is used

docker/base/launchTomcat.sh

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ echo " Multi node sticky routing jvmRoute ${JVM_ROUTE}"
3838
echo " Admin username ADMIN_USER ${ADMIN_USER}"
3939
echo " Admin password ADMIN_PASSWORD ${ADMIN_PASSWORD}"
4040
echo " Run tomcat with debug DEBUG ${DEBUG}"
41-
echo " Run tomcat with debug LOG_FILE_TO_CONSOLE ${LOG_FILE_TO_CONSOLE}"
41+
echo " An addition log file LOG_FILE_TO_CONSOLE ${LOG_FILE_TO_CONSOLE}"
4242
echo " Tomcat Manager available MANAGER ${MANAGER}"
4343
echo " Multi web app shared cache SHARE_CACHE ${SHARE_CACHE}"
4444
echo " Extra firefly properties FIREFLY_OPTS ${FIREFLY_OPTS}"
@@ -80,12 +80,6 @@ if [ "$SHARE_CACHE" = "true" ] ||[ "$SHARE_CACHE" = "t" ] ||[ "$SHARE_CACHE" = "
8080
./setupSharedCacheJars.sh
8181
fi
8282

83-
84-
rm -rf /usr/local/tomcat/webapps/examples
85-
rm -rf /usr/local/tomcat/webapps/docs
86-
rm -rf /usr/local/tomcat/webapps/host-manager
87-
rm -rf /usr/local/tomcat/webapps/ROOT
88-
8983
if [ "$MANAGER" != "true" ] && [ "$MANAGER" != "t" ] && [ "$MANAGER" != "1" ] && \
9084
[ "$MANAGER" != "TRUE" ] && [ "$MANAGER" != "True" ] ; then
9185
rm -r /usr/local/tomcat/webapps/manager

0 commit comments

Comments
 (0)