diff --git a/linux/ecosystem/electron-release-server/docker-entrypoint.sh b/linux/ecosystem/electron-release-server/docker-entrypoint.sh new file mode 100755 index 000000000..7005f9f55 --- /dev/null +++ b/linux/ecosystem/electron-release-server/docker-entrypoint.sh @@ -0,0 +1,11 @@ +#!/bin/bash + +echo "=============================================" +echo node $(node --version) +echo npm $(npm --version) +echo yarn $(yarn --version) +echo "=============================================" +echo "[nodejs] Electron Release Server isStarting up" +echo "=============================================" + +npm start diff --git a/linux/ecosystem/postgres/10/Dockerfile b/linux/ecosystem/postgres/10/Dockerfile index 5ecee8d3a..149d22520 100644 --- a/linux/ecosystem/postgres/10/Dockerfile +++ b/linux/ecosystem/postgres/10/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/11/Dockerfile b/linux/ecosystem/postgres/11/Dockerfile index 5db8d5879..cc6a65f9e 100644 --- a/linux/ecosystem/postgres/11/Dockerfile +++ b/linux/ecosystem/postgres/11/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/12/Dockerfile b/linux/ecosystem/postgres/12/Dockerfile index 3a80443a7..28e09b43b 100644 --- a/linux/ecosystem/postgres/12/Dockerfile +++ b/linux/ecosystem/postgres/12/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/13/Dockerfile b/linux/ecosystem/postgres/13/Dockerfile index e8cbe256b..201112140 100644 --- a/linux/ecosystem/postgres/13/Dockerfile +++ b/linux/ecosystem/postgres/13/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/14/Dockerfile b/linux/ecosystem/postgres/14/Dockerfile index 8cae46765..779b9c992 100644 --- a/linux/ecosystem/postgres/14/Dockerfile +++ b/linux/ecosystem/postgres/14/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/9.4/Dockerfile b/linux/ecosystem/postgres/9.4/Dockerfile index d09a1fbb4..8400dec43 100644 --- a/linux/ecosystem/postgres/9.4/Dockerfile +++ b/linux/ecosystem/postgres/9.4/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/9.5/Dockerfile b/linux/ecosystem/postgres/9.5/Dockerfile index 29cd92931..3bfcd9054 100644 --- a/linux/ecosystem/postgres/9.5/Dockerfile +++ b/linux/ecosystem/postgres/9.5/Dockerfile @@ -53,9 +53,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/9.6/Dockerfile b/linux/ecosystem/postgres/9.6/Dockerfile index 1a4507f5b..49c89a171 100644 --- a/linux/ecosystem/postgres/9.6/Dockerfile +++ b/linux/ecosystem/postgres/9.6/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/postgres/latest/Dockerfile b/linux/ecosystem/postgres/latest/Dockerfile index 8cae46765..779b9c992 100644 --- a/linux/ecosystem/postgres/latest/Dockerfile +++ b/linux/ecosystem/postgres/latest/Dockerfile @@ -52,9 +52,15 @@ ENV PGDATA /var/lib/postgresql/data VOLUME /var/lib/postgresql/data WORKDIR /var/lib/postgresql/data -COPY ./docker-entrypoint.sh / +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD pg_isready -h localhost -p 5433 || exit 1 -ENTRYPOINT ["/docker-entrypoint.sh"] +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] # We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL # calls "Fast Shutdown mode" wherein new connections are disallowed and any diff --git a/linux/ecosystem/qbittorrent/latest/Dockerfile b/linux/ecosystem/qbittorrent/latest/Dockerfile index 611555133..4b65b463f 100644 --- a/linux/ecosystem/qbittorrent/latest/Dockerfile +++ b/linux/ecosystem/qbittorrent/latest/Dockerfile @@ -26,7 +26,6 @@ RUN apt-get update && \ apt install -y --allow-unauthenticated --allow-downgrades \ qbittorrent-nox - ################################################################## # other customisations ################################################################## @@ -44,7 +43,15 @@ RUN apt clean -y && \ VOLUME ${QBT_DIR} +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD curl -f http://localhost:8282/ || exit 1 + +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +#Final config EXPOSE 8282 -COPY entrypoint.sh /entrypoint.sh -ENTRYPOINT /entrypoint.sh \ No newline at end of file +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] diff --git a/linux/ecosystem/qbittorrent/latest/entrypoint.sh b/linux/ecosystem/qbittorrent/latest/docker-entrypoint.sh similarity index 100% rename from linux/ecosystem/qbittorrent/latest/entrypoint.sh rename to linux/ecosystem/qbittorrent/latest/docker-entrypoint.sh diff --git a/linux/ecosystem/qbittorrent/stable/Dockerfile b/linux/ecosystem/qbittorrent/stable/Dockerfile index 8ed5af42c..21e60accd 100644 --- a/linux/ecosystem/qbittorrent/stable/Dockerfile +++ b/linux/ecosystem/qbittorrent/stable/Dockerfile @@ -26,7 +26,6 @@ RUN apt-get update && \ apt install -y --allow-unauthenticated --allow-downgrades \ qbittorrent-nox - ################################################################## # other customisations ################################################################## @@ -44,7 +43,15 @@ RUN apt clean -y && \ VOLUME ${QBT_DIR} +#healthcheck. good practice +HEALTHCHECK --interval=2m --timeout=3s CMD curl -f http://localhost:8282/ || exit 1 + +# Add image configuration and scripts +COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh +RUN chmod 755 /usr/bin/docker-entrypoint.sh + +#Final config EXPOSE 8282 -COPY entrypoint.sh /entrypoint.sh -ENTRYPOINT /entrypoint.sh \ No newline at end of file +ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"] +CMD ["docker-entrypoint.sh"] diff --git a/linux/ecosystem/qbittorrent/stable/entrypoint.sh b/linux/ecosystem/qbittorrent/stable/docker-entrypoint.sh similarity index 100% rename from linux/ecosystem/qbittorrent/stable/entrypoint.sh rename to linux/ecosystem/qbittorrent/stable/docker-entrypoint.sh