fixup db permissions
authorAndy Witter <awitter@georgialibraries.org>
Tue, 10 Dec 2019 20:06:37 +0000 (15:06 -0500)
committerAndy Witter <awitter@georgialibraries.org>
Tue, 10 Dec 2019 20:06:37 +0000 (15:06 -0500)
templates/setup.sh

index c53a89a..509deed 100755 (executable)
@@ -433,7 +433,6 @@ then
        #       fi
        #fi
        ### Set file ownership correctly on /etc/postgres
-       chown -R postgres:postgres /etc/postgres
        Add_EG_DB_User
 
     fi
@@ -863,6 +862,14 @@ then
     chown -R opensrf:opensrf /home/opensrf
 fi
 
+if cat /etc/hostname|grep -q db0
+then
+    Add_EG_DB_User
+    chown -R postgres:postgres /etc/postgres
+    echo;echo "WARNING !!Restart the server before continuing"
+fi
+
+
 echo
 echo "Done! This system is now configured as tar_file for evergreen $EG_VER"
 echo hostname for this node is $(cat /etc/hostname)