Hello all,
With this script, you can import multiple DirectAdmin backups and restore them all at once in HestiaCP. The script will process each DirectAdmin backup file one by one.
You can download and run the script using the commands below. If the ‘v-import-directadmin’ script is not already present in your installation, the script will automatically download it for you.
wget -O import_da.sh https://gist.githubusercontent.com/ricardo777/7a77376f1da4766f9de6ffc49878e875/raw/1ffa8735e8574c2e674796ed3e33b71109ed9675/import_da.sh
chmod +x import_da.sh
./import_da.sh
Configuration Options:
Before running the script, ensure you have the correct paths and parameters set within the script:
- Backup Directory:
BACKUP_DIR="/root/daimport/backups"
- Log File:
LOG_FILE="/root/daimport/da-import-log.txt"
These settings should already be in the script.
For the import script (v-import-directadmin
), you can set the following parameters within the script if necessary:
debug=1
(Enable debugging)hestia_package=default
(Specify Hestia package)letsencrypt_enable=1
(Enable Let’s Encrypt)addusertext='IMPORTED'
(Custom user text, will be added in ‘Contact Name’ in HestiaCP user account)tmp_dir='tmp_dir_da_backup'
(Temporary directory for backups)