From 8dc4ee7159e19d027a3c2b2f081c57e56f98cacf Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Fri, 9 Jan 2026 11:33:53 +0200 Subject: Remove 'user nginx;' directive to fix nginx worker errors When running as root with fsGroup, nginx workers fail trying to setgid. Remove the 'user nginx;' directive from nginx.conf at startup using sed. This allows nginx to run workers as root without permission errors. --- f3s/git-server/helm-chart/templates/deployment.yaml | 2 ++ 1 file changed, 2 insertions(+) (limited to 'f3s/git-server') diff --git a/f3s/git-server/helm-chart/templates/deployment.yaml b/f3s/git-server/helm-chart/templates/deployment.yaml index c077aa5..12a235a 100644 --- a/f3s/git-server/helm-chart/templates/deployment.yaml +++ b/f3s/git-server/helm-chart/templates/deployment.yaml @@ -69,6 +69,8 @@ spec: command: ["/bin/sh", "-c"] args: - | + # Remove 'user nginx;' directive to avoid setgid errors when running as root + sed -i 's/^user nginx;//' /etc/nginx/nginx.conf spawn-fcgi -s /var/run/fcgiwrap.sock -n -- /usr/bin/fcgiwrap & exec nginx -g 'daemon off;' ports: -- cgit v1.2.3