mirror of
https://github.com/octoleo/syncthing.git
synced 2024-12-22 10:58:57 +00:00
parent
a64ae36bcc
commit
9f8e6966d8
@ -14,8 +14,10 @@ if [ "$(id -u)" = '0' ]; then
|
||||
setcap "$PCAP" "$binary"
|
||||
fi
|
||||
|
||||
chown "${PUID}:${PGID}" "${HOME}" \
|
||||
&& exec su-exec "${PUID}:${PGID}" \
|
||||
# Chown may fail, which may cause us to be unable to start; but maybe
|
||||
# it'll work anyway, so we let the error slide.
|
||||
chown "${PUID}:${PGID}" "${HOME}" || true
|
||||
exec su-exec "${PUID}:${PGID}" \
|
||||
env HOME="$HOME" "$@"
|
||||
else
|
||||
exec "$@"
|
||||
|
Loading…
Reference in New Issue
Block a user