remove hard-coded uid 1000
This commit is contained in:
parent
ae4e3f20ac
commit
ab18396e89
@ -15,8 +15,8 @@ spec:
|
||||
app.kubernetes.io/name: notes
|
||||
spec:
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
runAsUser: {{ APP_USER_ID }}
|
||||
runAsGroup: {{ APP_USER_ID }}
|
||||
containers:
|
||||
- name: notes
|
||||
image: {{ NOTES_DOCKER_IMAGE }}
|
||||
|
||||
@ -1 +1 @@
|
||||
setowner 1000 /mounts/notes
|
||||
setowner {{ APP_USER_ID }} /mounts/notes
|
||||
|
||||
@ -21,7 +21,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
|
||||
RUN ln -s /usr/bin/python3 /usr/bin/python
|
||||
|
||||
###### Git-clone Notes repo ######
|
||||
ARG APP_USER_ID=1000
|
||||
ARG APP_USER_ID={{ HOST_USER_ID }}
|
||||
RUN useradd --home-dir /app --create-home --shell /bin/bash --uid ${APP_USER_ID} app
|
||||
USER ${APP_USER_ID}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user