I'm getting this error when I run my Dockerfile.
[FATAL tini (7)] exec /docker-entrypoint.sh failed: No such file or directory
The docker build command runs fine but when I try to run it I get this issue.
It's not a permissions issue since I have set the full read/write permissions for the file via chmod 777 command.
Any idea what I'm missing here. Below is a snippet from my Dockerfile
ARG base_image_name=tomcat
ARG base_image_version=9-jdk11-openjdk-slim
FROM $base_image_name:$base_image_version
ARG component_exe
COPY docker-entrypoint.sh $component_exe /
ENV APP_ROOT=/usr/local/tomcat
ENV component_runtime=${APP_ROOT}/webapps/$component_exe
ENV APP_USER=uat
# Install all required packages and set appropriate access permissions
RUN \
apt-get -y update && \
apt-get -y upgrade && \
apt-get install jq bash ca-certificates tini && \
adduser --disabled-password --gecos "" ${APP_USER} && \
mkdir -p ${APP_ROOT}/temp && \
mkdir -p ${APP_ROOT}/bin && \
mkdir -p ${APP_ROOT}/webapps && \
chmod 777 ${APP_ROOT}/webapps && \
chown -R ${APP_USER}:root ${APP_ROOT} && \
chmod 777 /docker-entrypoint.sh && \
chmod -R g=u ${APP_ROOT} && \
find / -name *.war && \
find / -name *tini* && \
find / -name *-entrypoint.sh && \
mv /$component_exe /usr/local/tomcat/webapps && \
chown -R :root /usr/local/openjdk-11/lib/security/cacerts && \
chmod 660 /usr/local/openjdk-11/lib/security/cacerts
EXPOSE 8080/tcp
ENTRYPOINT ["/usr/bin/tini", "--", "/docker-entrypoint.sh"]
# Start Tomcat Server.
CMD ["catalina.sh", "run"]