Skip to content

Commit 3ab7104

Browse files
authored
Open-webui add .env backup and restore functionality from older versions (#9592)
1 parent a06cab3 commit 3ab7104

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

ct/openwebui.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ function update_script() {
3333
msg_info "Creating Backup"
3434
mkdir -p /opt/open-webui-backup
3535
cp -a /opt/open-webui/backend/data /opt/open-webui-backup/data || true
36+
cp -a /opt/open-webui/.env /opt/open-webui-backup/.env || true
3637
msg_ok "Created Backup"
3738

3839
msg_info "Removing legacy installation"
@@ -48,6 +49,7 @@ function update_script() {
4849
msg_info "Restoring data"
4950
mkdir -p /root/.open-webui
5051
cp -a /opt/open-webui-backup/data/* /root/.open-webui/ || true
52+
cp -a /opt/open-webui-backup/.env /root/.env || true
5153
rm -rf /opt/open-webui-backup || true
5254
msg_ok "Restored data"
5355

0 commit comments

Comments
 (0)