We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e7ee1be commit 23d2a81Copy full SHA for 23d2a81
Dockerfile
@@ -19,6 +19,10 @@ RUN rm -r /etc/nginx/conf.d/ && ln -s "${CONFIG_DIR}/.out/conf.d" /etc/nginx/con
19
RUN apk --no-cache add libcap && \
20
setcap cap_net_bind_service=+ep /usr/sbin/nginx && \
21
apk --no-cache del libcap
22
-USER nginx
+
23
+# Needs to be set to numeric value to be compatible with Kubernetes PodSecurityContext#runAsNonRoot
24
+# Setting this to `nginx` and `runAsNonRoot: true` would result in runtime error:
25
+# "Error: container has runAsNonRoot and image has non-numeric user (nginx), cannot verify user is non-root"
26
+USER 101:101
27
28
ENTRYPOINT ["/docker-entrypoint.sh"]
0 commit comments