Fix hourly daemons

This commit is contained in:
Bob Mottram 2017-04-02 21:44:49 +01:00
parent 1e5784cd8e
commit 9ec20428da
2 changed files with 5 additions and 3 deletions

View File

@ -225,8 +225,8 @@ function gnusocial_create_database {
function gnusocial_running_script {
# check that the daemon is running
echo '#!/bin/bash' > /etc/cron.hourly/gnusocial-daemons
echo -n 'daemon_lines=$(ps aux | grep "'
echo -n "${GNUSOCIAL_DOMAIN_NAME}"
echo -n 'daemon_lines=$(ps aux | grep "'>> /etc/cron.hourly/gnusocial-daemons
echo -n "${GNUSOCIAL_DOMAIN_NAME}">> /etc/cron.hourly/gnusocial-daemons
echo '/htdocs/scripts/queuedaemon.php" | grep "/var/www")' >> /etc/cron.hourly/gnusocial-daemons
echo 'if [[ $daemon_lines != *"/var/www/"* ]]; then' >> /etc/cron.hourly/gnusocial-daemons

View File

@ -199,7 +199,9 @@ function postactiv_create_database {
function postactiv_running_script {
# check that the daemon is running
echo '#!/bin/bash' > /etc/cron.hourly/postactiv-daemons
echo 'daemon_lines=$(ps aux | grep "${POSTACTIV_DOMAIN_NAME}/htdocs/scripts/queuedaemon.php" | grep "/var/www")' >> /etc/cron.hourly/postactiv-daemons
echo -n 'daemon_lines=$(ps aux | grep "' >> /etc/cron.hourly/postactiv-daemons
echo -n "${POSTACTIV_DOMAIN_NAME}" >> /etc/cron.hourly/postactiv-daemons
echo '/htdocs/scripts/queuedaemon.php" | grep "/var/www")' >> /etc/cron.hourly/postactiv-daemons
echo 'if [[ $daemon_lines != *"/var/www/"* ]]; then' >> /etc/cron.hourly/postactiv-daemons
echo " ADMIN_USER=\$(cat $COMPLETION_FILE | grep 'Admin user' | awk -F ':' '{print \$2}')" >> /etc/cron.hourly/postactiv-daemons