| 123456789101112131415161718192021222324252627282930313233343536373839 |
- #!/bin/bash
- # info: backup all users
- # options: none
- #
- # The function backups all system users.
- #----------------------------------------------------------#
- # Variable&Function #
- #----------------------------------------------------------#
- # Importing system enviroment as we run this script
- # mostly by cron wich not read it by itself
- source /etc/profile.d/vesta.sh
- # Importing variables
- source $VESTA/conf/vesta.conf
- source $VESTA/func/shared.sh
- #----------------------------------------------------------#
- # Action #
- #----------------------------------------------------------#
- user_list=$(ls $V_USERS/)
- # Updating user billing
- for user in $user_list; do
- $BIN/v_backup_user $user &>> $VESTA/logs/backup.log
- done
- #----------------------------------------------------------#
- # Vesta #
- #----------------------------------------------------------#
- # Logging
- log_event "$OK" "$EVENT"
- exit
|