mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-02-14 19:41:51 +00:00
Fix restore backup from server
This commit is contained in:
parent
6a51266e0c
commit
9470cfc429
1 changed files with 5 additions and 2 deletions
|
@ -731,7 +731,10 @@ _vps_firewall_redirect_port() {
|
|||
checkfw=$(echo "$vpsfwlist" | grep "$src_dport # OMR $username redirect router $src_dport port $protoi")
|
||||
else
|
||||
comment=""
|
||||
[ -n "$src_dip" ] && comment=" to $src_dip"
|
||||
[ -n "$src_dip" ] && {
|
||||
comment=" to $src_dip"
|
||||
iptables-save --counters | sed "s:-d $src_dip/32::g" | iptables-restore -w
|
||||
}
|
||||
[ -n "$src_ip" ] && comment=" from $src_ip"
|
||||
checkfw=$(echo "$vpsfwlist" | grep "# OMR $username redirect router $src_dport port $protoi${comment}")
|
||||
fi
|
||||
|
@ -1326,7 +1329,7 @@ _backup_get_and_apply() {
|
|||
backup_sha256sum="$(echo "$vps_backup" | jsonfilter -q -e '@.sha256sum')"
|
||||
[ -n "$backup_data" ] && {
|
||||
echo $backup_data | base64 -d > /tmp/backup.tar.gz
|
||||
sysupgrade -t /tmp/backup.tar.gz
|
||||
sysupgrade -r /tmp/backup.tar.gz
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue