changing paths, adding web-user-listing

This commit is contained in:
2015-06-12 12:35:12 +03:00
parent 92bf42faec
commit 5b22e79d45
4 changed files with 16 additions and 2 deletions

View File

@@ -1,6 +1,6 @@
#!/bin/bash
# echo "0 11 * * * root /root/scripts/backup.sh" > /etc/cron.d/backup
# echo "0 11 * * * root /root/scripts/server/backup.sh" > /etc/cron.d/backup
BAKDIR=/root/backup/configsave

13
server/list-web-users.sh Executable file
View File

@@ -0,0 +1,13 @@
#!/bin/bash
DOMAINROOT="mit.tareo-tz.org"
find /var/www/* -maxdepth 0 -type d -print0 | while IFS= read -r -d $'\0' line; do
USER=$(basename $line)
DOMAIN="$USER.$DOMAINROOT"
if [ ! "$USER" == "html" ]; then
echo "<li><a href=\"http://$DOMAIN\">$DOMAIN</a></li>"
fi
done

View File

@@ -112,6 +112,7 @@ cat > /etc/apache2/sites-available/$USER.conf << EOF
FCGIWrapper $WEBDIR/php-fcgi/php-fcgi-starter .php
Order allow,deny
allow from all
AllowOverride All
</Directory>
ErrorLog $WEBDIR/logs/error.log
LogLevel warn

View File

@@ -1,6 +1,6 @@
#!/bin/bash
# echo "* * * * * root /root/scripts/sync-public.sh" > /etc/cron.d/sync-public
# echo "* * * * * root /root/scripts/server/sync-public.sh" > /etc/cron.d/sync-public
for ((i = 1; i <= 4; i++)); do # Execute 4 times in a row
# echo $(date) >> /var/share/cron.log