From 8dbba9fe7c2178c0aaf224ec5b8bd1b7e9059eea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julian=20K=C3=B6nig?= <33655937+jkoenig134@users.noreply.github.com> Date: Wed, 29 Jan 2025 16:25:00 +0100 Subject: [PATCH] Arm64 images containing amd tini version (#356) * fix: install tini from deb * fix: change path * chore: add healthcheck * chore: remove double spaces --- Dockerfile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 79623f7f..2f370efe 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,8 +15,10 @@ RUN .ci/writeBuildInformation.sh FROM node:23.6.1-slim -ENV TINI_VERSION=v0.19.0 -ADD --chmod=755 https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /usr/local/bin/tini +HEALTHCHECK --interval=30s --timeout=5s --start-period=5s --retries=5 CMD ["node","-e",'require("http").get("http://localhost/health", res => process.exit(res.statusCode === 200 ? 0 : 1))'] +LABEL org.opencontainers.image.source="https://github.com/nmshd/connector" + +RUN apt-get update && apt-get -qq install -y --no-install-recommends tini && apt-get clean && rm -rf /var/lib/apt/lists/* RUN mkdir -p /var/log/enmeshed-connector && chown -R node:node /var/log/enmeshed-connector @@ -29,9 +31,7 @@ RUN npm ci --omit=dev COPY --from=builder /usr/app/dist/ dist/ -LABEL org.opencontainers.image.source="https://github.com/nmshd/connector" - USER node -ENTRYPOINT ["/usr/local/bin/tini", "--", "node", "/usr/app/dist/index.js"] +ENTRYPOINT ["/usr/bin/tini", "--", "node", "/usr/app/dist/index.js"] CMD ["start"]