Skip to content
Snippets Groups Projects
Commit f6b0037c authored by Bob Mottram's avatar Bob Mottram
Browse files

Stop daemons from root

parent e747a001
No related branches found
No related tags found
No related merge requests found
......@@ -404,7 +404,7 @@ function restore_local_gnusocial {
gnusocial_dir=/var/www/${GNUSOCIAL_DOMAIN_NAME}/htdocs
# stop the daemons
cd $gnusocial_dir
su -c "sh scripts/stopdaemons.sh" -s /bin/sh www-data
scripts/stopdaemons.sh
function_check gnusocial_create_database
gnusocial_create_database
......@@ -452,7 +452,7 @@ function restore_remote_gnusocial {
# stop the daemons
cd /var/www/${GNUSOCIAL_DOMAIN_NAME}/htdocs
su -c "sh scripts/stopdaemons.sh" -s /bin/sh www-data
scripts/stopdaemons.sh
function_check gnusocial_create_database
gnusocial_create_database
......@@ -487,7 +487,7 @@ function remove_gnusocial {
fi
if [ -f /var/www/$GNUSOCIAL_DOMAIN_NAME/htdocs/scripts/stopdaemons.sh ]; then
cd /var/www/$GNUSOCIAL_DOMAIN_NAME/htdocs/scripts
su -c "sh scripts/stopdaemons.sh" -s /bin/sh www-data
scripts/stopdaemons.sh
fi
kill_pid=$(ps aux | grep /var/www/$GNUSOCIAL_DOMAIN_NAME/htdocs/scripts/queuedaemon.php | awk -F ' ' '{print $2}' | head -n 1)
kill -9 $kill_pid
......
......@@ -411,7 +411,7 @@ function restore_local_postactiv {
postactiv_dir=/var/www/${POSTACTIV_DOMAIN_NAME}/htdocs
# stop the daemons
cd $postactiv_dir
su -c "sh scripts/stopdaemons.sh" -s /bin/sh www-data
scripts/stopdaemons.sh
function_check postactiv_create_database
postactiv_create_database
......@@ -455,7 +455,7 @@ function restore_remote_postactiv {
# stop the daemons
cd /var/www/${POSTACTIV_DOMAIN_NAME}/htdocs
su -c "sh scripts/stopdaemons.sh" -s /bin/sh www-data
scripts/stopdaemons.sh
function_check postactiv_create_database
postactiv_create_database
......@@ -489,7 +489,7 @@ function remove_postactiv {
fi
if [ -f /var/www/$POSTACTIV_DOMAIN_NAME/htdocs/scripts/stopdaemons.sh ]; then
cd /var/www/$POSTACTIV_DOMAIN_NAME/htdocs/scripts
su -c "sh scripts/stopdaemons.sh" -s /bin/sh www-data
scripts/stopdaemons.sh
fi
kill_pid=$(ps aux | grep /var/www/$POSTACTIV_DOMAIN_NAME/htdocs/scripts/queuedaemon.php | awk -F ' ' '{print $2}' | head -n 1)
kill -9 $kill_pid
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment