silence usermod on start

This commit is contained in:
Nick Sweeting 2020-11-23 00:59:50 -05:00
parent 75d4125e3e
commit 5b15c8e29e

View file

@ -9,8 +9,8 @@ GRID=$(stat --format="%g" "$DATA_DIR")
# If user is not root, modify the archivebox user+files to have the same uid,gid
if [[ "$USID" != 0 && "$GRID" != 0 ]]; then
usermod -u "$USID" "$ARCHIVEBOX_USER"
groupmod -g "$GRID" "$ARCHIVEBOX_USER"
usermod -u "$USID" "$ARCHIVEBOX_USER" > /dev/null 2>&1
groupmod -g "$GRID" "$ARCHIVEBOX_USER" > /dev/null 2>&1
chown -R "$USID":"$GRID" "/home/$ARCHIVEBOX_USER"
chown "$USID":"$GRID" "$DATA_DIR"
chown "$USID":"$GRID" "$DATA_DIR/*" > /dev/null 2>&1 || true