mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-24 20:02:43 +01:00
specify user in rootless container numerically (#16361)
* specify user in rootless container numerically With kubernetes' PodSecurityPolicy set to runAsNonRoot it will not allow starting the container. The error message is ``` Error: container has runAsNonRoot and image has non-numeric user (git), cannot verify user is non-root ``` The `USER` directive has to be numerical for that to work. * mention the name of the uid/gid Co-authored-by: 6543 <6543@obermui.de>
This commit is contained in:
parent
d06f9ce274
commit
5e819ee1de
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@ COPY docker/rootless /
|
|||
COPY --from=build-env --chown=root:root /go/src/code.gitea.io/gitea/gitea /usr/local/bin/gitea
|
||||
COPY --from=build-env --chown=root:root /go/src/code.gitea.io/gitea/environment-to-ini /usr/local/bin/environment-to-ini
|
||||
|
||||
USER git:git
|
||||
USER 1000:1000 # git:git
|
||||
ENV GITEA_WORK_DIR /var/lib/gitea
|
||||
ENV GITEA_CUSTOM /var/lib/gitea/custom
|
||||
ENV GITEA_TEMP /tmp/gitea
|
||||
|
|
Loading…
Reference in a new issue