From 9da8e9654c54702e557c992674c240f6321e1fc3 Mon Sep 17 00:00:00 2001 From: Sukalpo Mitra Date: Sat, 27 Jan 2024 11:20:38 +0800 Subject: [PATCH] Removed commneted lines and organised code into docker folder --- Dockerfile | 11 +++-------- entrypoint.sh => docker/entrypoint.sh | 0 {etc => docker/etc}/bashrc.d/init.sh | 0 {etc => docker/etc}/dircolors | 0 {etc => docker/etc}/vim/vimrc.local | 0 {opt => docker/opt}/jetty/etc/jetty-logging.xml | 0 {opt => docker/opt}/jetty/etc/jetty.conf | 0 7 files changed, 3 insertions(+), 8 deletions(-) rename entrypoint.sh => docker/entrypoint.sh (100%) rename {etc => docker/etc}/bashrc.d/init.sh (100%) rename {etc => docker/etc}/dircolors (100%) rename {etc => docker/etc}/vim/vimrc.local (100%) rename {opt => docker/opt}/jetty/etc/jetty-logging.xml (100%) rename {opt => docker/opt}/jetty/etc/jetty.conf (100%) diff --git a/Dockerfile b/Dockerfile index 45481153..0098bef0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,17 +3,12 @@ FROM ubuntu:22.04 # Run Debian in non interactive mode ENV DEBIAN_FRONTEND noninteractive -# Install Sismics repository -RUN apt-get update && apt-get install -y apt-transport-https ca-certificates software-properties-common curl gnupg tzdata -RUN curl -fsSL https://www.sismics.com/pgp | apt-key add - -# RUN add-apt-repository "deb [arch=amd64] https://nexus.sismics.com/repository/apt-bionic/ bionic main" - # Configure settings ENV LANG C.UTF-8 ENV LC_ALL C.UTF-8 RUN ln -fs /usr/share/zoneinfo/Europe/Paris /etc/localtime RUN dpkg-reconfigure -f noninteractive tzdata -COPY etc /etc +COPY docker/etc /etc RUN echo "for f in \`ls /etc/bashrc.d/*\`; do . \$f; done;" >> ~/.bashrc RUN apt-get -y -q install vim less procps unzip wget && \ rm -rf /var/lib/apt/lists/* @@ -37,7 +32,7 @@ WORKDIR /opt/jetty RUN chmod +x bin/jetty.sh # Init configuration -COPY opt /opt +COPY docker/opt /opt EXPOSE 8080 ENV JETTY_HOME /opt/jetty ENV JAVA_OPTIONS -Xmx512m @@ -88,7 +83,7 @@ ENV JAVA_OPTIONS -Xmx1g WORKDIR /app # Set the default command to run when starting the container -COPY entrypoint.sh /entrypoint.sh +COPY docker/entrypoint.sh /entrypoint.sh RUN chmod +x /entrypoint.sh CMD ["/entrypoint.sh"] diff --git a/entrypoint.sh b/docker/entrypoint.sh similarity index 100% rename from entrypoint.sh rename to docker/entrypoint.sh diff --git a/etc/bashrc.d/init.sh b/docker/etc/bashrc.d/init.sh similarity index 100% rename from etc/bashrc.d/init.sh rename to docker/etc/bashrc.d/init.sh diff --git a/etc/dircolors b/docker/etc/dircolors similarity index 100% rename from etc/dircolors rename to docker/etc/dircolors diff --git a/etc/vim/vimrc.local b/docker/etc/vim/vimrc.local similarity index 100% rename from etc/vim/vimrc.local rename to docker/etc/vim/vimrc.local diff --git a/opt/jetty/etc/jetty-logging.xml b/docker/opt/jetty/etc/jetty-logging.xml similarity index 100% rename from opt/jetty/etc/jetty-logging.xml rename to docker/opt/jetty/etc/jetty-logging.xml diff --git a/opt/jetty/etc/jetty.conf b/docker/opt/jetty/etc/jetty.conf similarity index 100% rename from opt/jetty/etc/jetty.conf rename to docker/opt/jetty/etc/jetty.conf