|
|
|
|
2949
|
}
|
2949
|
}
|
2950
|
|
2950
|
|
2951
|
function backup_to_friends_servers {
|
2951
|
function backup_to_friends_servers {
|
2952
|
- if grep -Fxq "backup_to_friends_servers" $COMPLETION_FILE; then
|
|
|
2953
|
- return
|
|
|
2954
|
- fi
|
|
|
2955
|
-
|
|
|
2956
|
# update crontab
|
2952
|
# update crontab
|
2957
|
echo '#!/bin/bash' > /etc/cron.daily/backuptofriends
|
2953
|
echo '#!/bin/bash' > /etc/cron.daily/backuptofriends
|
2958
|
echo "if [ -f /usr/local/bin/${PROJECT_NAME}-backup-remote ]; then" >> /etc/cron.daily/backuptofriends
|
2954
|
echo "if [ -f /usr/local/bin/${PROJECT_NAME}-backup-remote ]; then" >> /etc/cron.daily/backuptofriends
|
|
|
|
|
2961
|
echo " /usr/bin/${PROJECT_NAME}-backup-remote" >> /etc/cron.daily/backuptofriends
|
2957
|
echo " /usr/bin/${PROJECT_NAME}-backup-remote" >> /etc/cron.daily/backuptofriends
|
2962
|
echo 'fi' >> /etc/cron.daily/backuptofriends
|
2958
|
echo 'fi' >> /etc/cron.daily/backuptofriends
|
2963
|
chmod +x /etc/cron.daily/backuptofriends
|
2959
|
chmod +x /etc/cron.daily/backuptofriends
|
2964
|
-
|
|
|
2965
|
- echo 'backup_to_friends_servers' >> $COMPLETION_FILE
|
|
|
2966
|
}
|
2960
|
}
|
2967
|
|
2961
|
|
2968
|
function remove_default_user {
|
2962
|
function remove_default_user {
|