dockerfile

This commit is contained in:
LORENZO\pacio 2025-01-14 12:22:23 +01:00
parent 4e59bc90c1
commit cda7ab1c50

View File

@ -8,29 +8,31 @@ ARG GROUPNAME
# Create group and user with IDs passed from Docker Compose
RUN groupadd -g ${GROUP_ID} ${GROUPNAME} && useradd --no-log-init -u ${USER_ID} -g ${GROUP_ID} -m ${USERNAME} || true
#SUPPORTO A VERSIONI VECCHIE DI SQL SERVER (ERRORI SSL)
# Check if java.security exists at the correct path and remove any disabled algorithms
#RUN if [ -f /opt/java/openjdk/conf/security/java.security ]; then sed -i '/jdk.tls.disabledAlgorithms/d' /opt/java/openjdk/conf/security/java.security; else echo "java.security file not found"; fi
# Install necessary packages and clean up
# SUPPORTO A VERSIONI VECCHIE DI SQL SERVER (ERRORI SSL)
# Check if java.security exists at the correct path and remove any disabled algorithms
# RUN if [ -f /opt/java/openjdk/conf/security/java.security ]; then sed -i '/jdk.tls.disabledAlgorithms/d' /opt/java/openjdk/conf/security/java.security; else echo "java.security file not found"; fi
# Install necessary packages, including ping, telnet, openssl, and CA certificates, and clean up
RUN apt-get update && \
apt-get install -y gosu libreoffice && \
apt-get install -y \
iputils-ping \ # For ping
inetutils-telnet \ # For telnet
openssl \ # For openssl commands
ca-certificates \ # For SSL/TLS certificate validation
gosu \ # Existing requirement
libreoffice && \ # Existing requirement
apt-get clean && \
rm -rf /var/lib/apt/lists/*
rm -rf /var/lib/apt/lists/*
# CONFIG
COPY ./conf/catalina.properties /usr/local/tomcat/conf/catalina.properties
COPY ./conf/context.xml /usr/local/tomcat/conf/context.xml
COPY ./conf/server.xml /usr/local/tomcat/conf/server.xml
#librerie
# Librerie
COPY ./libs/ /usr/local/tomcat/lib/
#cartelle docfinance
RUN mkdir -p /usr/local/tomcat/docfinance_in && mkdir -p /usr/local/tomcat/docfinance_out
RUN chmod -R 775 /usr/local/tomcat/docfinance_in && chmod -R 775 /usr/local/tomcat/docfinance_out
# Set permissions on Tomcat directories
RUN chown -R ${USERNAME}:${GROUPNAME} /usr/local/tomcat
@ -40,4 +42,4 @@ RUN mkdir -p /home/${USERNAME}/.cache/dconf && \
USER ${USERNAME}
CMD ["catalina.sh", "run"]
CMD ["catalina.sh", "run"]