mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-06-03 06:09:36 +02:00
fix(openthread-br): preserve config during update (#14893)
This commit is contained in:
@@ -47,6 +47,10 @@ function update_script() {
|
|||||||
systemctl stop otbr-agent
|
systemctl stop otbr-agent
|
||||||
msg_ok "Stopped Services"
|
msg_ok "Stopped Services"
|
||||||
|
|
||||||
|
msg_info "Backing up Configuration"
|
||||||
|
cp /etc/default/otbr-agent /etc/default/otbr-agent.bak
|
||||||
|
msg_ok "Backed up Configuration"
|
||||||
|
|
||||||
msg_info "Updating Source"
|
msg_info "Updating Source"
|
||||||
$STD git reset --hard origin/main
|
$STD git reset --hard origin/main
|
||||||
$STD git submodule update --depth 1 --init --recursive
|
$STD git submodule update --depth 1 --init --recursive
|
||||||
@@ -91,6 +95,10 @@ EOF
|
|||||||
msg_ok "Configured Network"
|
msg_ok "Configured Network"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
msg_info "Restoring Configuration"
|
||||||
|
mv /etc/default/otbr-agent.bak /etc/default/otbr-agent
|
||||||
|
msg_ok "Restored Configuration"
|
||||||
|
|
||||||
msg_info "Starting Services"
|
msg_info "Starting Services"
|
||||||
systemctl start otbr-agent
|
systemctl start otbr-agent
|
||||||
systemctl start otbr-web
|
systemctl start otbr-web
|
||||||
|
|||||||
Reference in New Issue
Block a user