|
|
@ -52,7 +52,10 @@ function default_settings() { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
function update_script() { |
|
|
|
function update_script() { |
|
|
|
if [[ ! -f /etc/systemd/system/vaultwarden.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi |
|
|
|
if [[ ! -f /etc/systemd/system/vaultwarden.service ]]; then |
|
|
|
|
|
|
|
msg_error "No ${APP} Installation Found!" |
|
|
|
|
|
|
|
exit |
|
|
|
|
|
|
|
fi |
|
|
|
VAULT=$(curl -s https://api.github.com/repos/dani-garcia/vaultwarden/releases/latest | |
|
|
|
VAULT=$(curl -s https://api.github.com/repos/dani-garcia/vaultwarden/releases/latest | |
|
|
|
grep "tag_name" | |
|
|
|
grep "tag_name" | |
|
|
|
awk '{print substr($2, 2, length($2)-3) }') |
|
|
|
awk '{print substr($2, 2, length($2)-3) }') |
|
|
@ -96,7 +99,7 @@ msg_ok "Started Vaultwarden" |
|
|
|
|
|
|
|
|
|
|
|
msg_ok "$VAULT Update Successful" |
|
|
|
msg_ok "$VAULT Update Successful" |
|
|
|
echo -e "\n ⚠️ Ensure you set resources back to normal settings \n" |
|
|
|
echo -e "\n ⚠️ Ensure you set resources back to normal settings \n" |
|
|
|
exit; |
|
|
|
exit |
|
|
|
fi |
|
|
|
fi |
|
|
|
if [ "$UPD" == "2" ]; then |
|
|
|
if [ "$UPD" == "2" ]; then |
|
|
|
msg_info "Stopping Vaultwarden" |
|
|
|
msg_info "Stopping Vaultwarden" |
|
|
@ -116,7 +119,7 @@ msg_info "Starting Vaultwarden" |
|
|
|
systemctl start vaultwarden.service |
|
|
|
systemctl start vaultwarden.service |
|
|
|
msg_ok "Started Vaultwarden" |
|
|
|
msg_ok "Started Vaultwarden" |
|
|
|
msg_ok "$WVRELEASE Update Successful" |
|
|
|
msg_ok "$WVRELEASE Update Successful" |
|
|
|
exit; |
|
|
|
exit |
|
|
|
fi |
|
|
|
fi |
|
|
|
if [ "$UPD" == "3" ]; then |
|
|
|
if [ "$UPD" == "3" ]; then |
|
|
|
DIR=/usr/bin/vaultwarden |
|
|
|
DIR=/usr/bin/vaultwarden |
|
|
|