Change docker user (#3096)

- Running under 'inventree' user means that the mounted volume cannot be accessed
- Will need to return to this issue soon
This commit is contained in:
Oliver 2022-05-30 08:37:58 +10:00 committed by GitHub
parent 9430d1bbbe
commit 71ed181611
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -105,10 +105,9 @@ COPY docker/init.sh ${INVENTREE_MNG_DIR}/init.sh
WORKDIR ${INVENTREE_MNG_DIR} WORKDIR ${INVENTREE_MNG_DIR}
# Drop to the inventree user for the production image # Drop to the inventree user for the production image
RUN adduser inventree #RUN adduser inventree
RUN chown -R inventree:inventree ${INVENTREE_HOME} #RUN chown -R inventree:inventree ${INVENTREE_HOME}
#USER inventree
USER inventree
# Install InvenTree packages # Install InvenTree packages
RUN pip3 install --user --disable-pip-version-check -r ${INVENTREE_HOME}/requirements.txt RUN pip3 install --user --disable-pip-version-check -r ${INVENTREE_HOME}/requirements.txt