Only change user permissions if not in onion mode

This commit is contained in:
Bob Mottram 2017-05-27 19:09:06 +01:00
parent e2cb336792
commit 187a86c6bd
1 changed files with 5 additions and 3 deletions

View File

@ -299,9 +299,11 @@ function install_cryptpad_main {
# an unprivileged user to run as # an unprivileged user to run as
useradd -d $CRYPTPAD_DIR/ cryptpad useradd -d $CRYPTPAD_DIR/ cryptpad
chgrp -R ssl-cert /etc/letsencrypt if [[ $ONION_ONLY == "no" ]]; then
chmod -R g=rX /etc/letsencrypt chgrp -R ssl-cert /etc/letsencrypt
usermod -a -G ssl-cert cryptpad chmod -R g=rX /etc/letsencrypt
usermod -a -G ssl-cert cryptpad
fi
cd $CRYPTPAD_DIR cd $CRYPTPAD_DIR
git checkout $CRYPTPAD_COMMIT -b $CRYPTPAD_COMMIT git checkout $CRYPTPAD_COMMIT -b $CRYPTPAD_COMMIT