Merge commit 'jrollins/master'
[monkeysphere.git] / src / share / ma / setup
index 1685e5da797613a0151c2e5f8729ef071ce1a3e4..e77afff4299795c7a442bccf43e74dea1f2884e3 100644 (file)
 
 setup() {
     # make all needed directories
-    log debug "make authentication directory structure..."
+    log debug "checking authentication directory structure..."
     mkdir -p "${MADATADIR}"
-    chmod 750 "${MADATADIR}"
+    chmod 0750 "${MADATADIR}"
     chgrp "$MONKEYSPHERE_USER" "${MADATADIR}"
     mkdir -p "${MATMPDIR}"
-    chmod 750 "${MATMPDIR}"
+    chmod 0750 "${MATMPDIR}"
     chgrp "$MONKEYSPHERE_USER" "${MATMPDIR}"
     mkdir -p "${GNUPGHOME_CORE}"
-    chmod 700 "${GNUPGHOME_CORE}"
+    chmod 0700 "${GNUPGHOME_CORE}"
     mkdir -p "${GNUPGHOME_SPHERE}"
-    chmod 700 "${GNUPGHOME_SPHERE}"
+    chmod 0700 "${GNUPGHOME_SPHERE}"
+    mkdir -p "${SYSDATADIR}"/authorized_keys
 
     # deliberately replace the config files via truncation
     # FIXME: should we be dumping to tmp files and then moving atomically?