Rundeck – Shell Script Backup Sonicwall
How to create a Rundeck Job to Backup Sonicwall over FTP.
#!/bin/bash
set variables for easy changes
user=admin
password="SW_PASSWORD"
name=$1
host=$2
load from bash
/usr/bin/expect <"
send "export preferences ftp ftp.diegoluisi.eti.br dluisi "FTP_PASSWORD" $name-$(date +%Y-%m-%d).expn"
expect -re ".*NSA 3500>"
send "exitn"
EOF
Fala Diegão, BLZA??
vc pode deixar seu Script UNIVERSAL mundando a linha “expect -re “.*NSA 3500>”” por “expect -re “.*>””
Falow Brother
Obrigado Ernander, ele já esta funcionando universal.
Mas vou recriar essa linha, abraço!