feat: add Docker publish workflow for multi-architecture builds

fix: Dockerfile: make image arbitrary-UID friendly for OpenShift (group 0 + g+rwX, SGID, no fixed USER)
This commit is contained in:
LIESLEN
2025-08-14 13:54:31 +02:00
parent 438e5d966f
commit 4525ac687b
2 changed files with 63 additions and 0 deletions
+9
View File
@@ -170,6 +170,15 @@ EXPOSE 8080
HEALTHCHECK CMD curl --silent --fail http://localhost:${PORT:-8080}/health | jq -ne 'input.status == true' || exit 1
# Minimal, atomic permission hardening for OpenShift (arbitrary UID):
# - Group 0 owns /app and /root
# - Directories are group-writable and have SGID so new files inherit GID 0
RUN set -eux; \
chgrp -R 0 /app /root || true; \
chmod -R g+rwX /app /root || true; \
find /app -type d -exec chmod g+s {} + || true; \
find /root -type d -exec chmod g+s {} + || true
USER $UID:$GID
ARG BUILD_HASH