Browse Source

Only change user permissions if not in onion mode

Bob Mottram 8 years ago
parent
commit
187a86c6bd
1 changed files with 5 additions and 3 deletions
  1. 5
    3
      src/freedombone-app-cryptpad

+ 5
- 3
src/freedombone-app-cryptpad View File

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