Update flatnotes.sh
This commit is contained in:
parent
04386cd5b7
commit
8b404191e8
@ -34,8 +34,8 @@ function update_script() {
|
|||||||
msg_ok "Stopped Service"
|
msg_ok "Stopped Service"
|
||||||
|
|
||||||
msg_info "Backing up Configuration and Data"
|
msg_info "Backing up Configuration and Data"
|
||||||
cp /opt/flatnotes/.env /opt/.env.bak
|
cp /opt/flatnotes/.env /opt/flatnotes.env
|
||||||
cp -r /opt/flatnotes/data /opt/data_backup
|
cp -r /opt/flatnotes/data /opt/flatnotes_data_backup
|
||||||
msg_ok "Backed up Configuration and Data"
|
msg_ok "Backed up Configuration and Data"
|
||||||
|
|
||||||
fetch_and_deploy_gh_release "flatnotes" "dullage/flatnotes"
|
fetch_and_deploy_gh_release "flatnotes" "dullage/flatnotes"
|
||||||
@ -54,10 +54,10 @@ function update_script() {
|
|||||||
msg_ok "Updated Backend"
|
msg_ok "Updated Backend"
|
||||||
|
|
||||||
msg_info "Restoring Configuration and Data"
|
msg_info "Restoring Configuration and Data"
|
||||||
cp /opt/.env.bak /opt/flatnotes/.env
|
cp /opt/flatnotes.env /opt/flatnotes/.env
|
||||||
cp -r /opt/data_backup/. /opt/flatnotes/data
|
cp -r /opt/flatnotes_data_backup/. /opt/flatnotes/data
|
||||||
rm -f /opt/.env.bak
|
rm -f /opt/flatnotes.env
|
||||||
rm -r /opt/data_backup
|
rm -r /opt/flatnotes_data_backup
|
||||||
msg_ok "Restored Configuration and Data"
|
msg_ok "Restored Configuration and Data"
|
||||||
|
|
||||||
msg_info "Starting Service"
|
msg_info "Starting Service"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user