docker(minor): give user a fixed UID, use --chown flag for docker COPY
This commit is contained in:
parent
c1dae0b599
commit
432176ea2f
|
@ -1,9 +1,8 @@
|
||||||
FROM docker.beryju.org/passbook/base:latest
|
FROM docker.beryju.org/passbook/base:latest
|
||||||
|
|
||||||
COPY ./passbook/ /app/passbook
|
COPY --chown=passbook:passbook ./passbook/ /app/passbook
|
||||||
COPY ./manage.py /app/
|
COPY ./manage.py /app/
|
||||||
COPY ./docker/uwsgi.ini /app/
|
COPY ./docker/uwsgi.ini /app/
|
||||||
RUN chown -R passbook: /app
|
|
||||||
|
|
||||||
WORKDIR /app/
|
WORKDIR /app/
|
||||||
|
|
||||||
|
|
|
@ -15,5 +15,4 @@ RUN apt-get update && \
|
||||||
RUN pipenv lock -r > requirements.txt && \
|
RUN pipenv lock -r > requirements.txt && \
|
||||||
pipenv --rm && \
|
pipenv --rm && \
|
||||||
pip install -r requirements.txt --no-cache-dir && \
|
pip install -r requirements.txt --no-cache-dir && \
|
||||||
adduser --system --no-create-home passbook && \
|
adduser --system --no-create-home --uid 1000 --group --home /app passbook
|
||||||
chown -R passbook /app
|
|
||||||
|
|
Reference in New Issue