Fix linkwarden update (#1565)

This commit is contained in:
Gerhard Burger 2025-01-18 11:39:02 +01:00 committed by GitHub
parent e683fd900f
commit d1f5556ce3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -40,6 +40,7 @@ function update_script() {
msg_info "Updating ${APP} to ${RELEASE}"
cd /opt
mv /opt/linkwarden/.env /opt/.env
rm -rf /opt/linkwarden
RELEASE=$(curl -s https://api.github.com/repos/linkwarden/linkwarden/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
wget -q "https://github.com/linkwarden/linkwarden/archive/refs/tags/${RELEASE}.zip"
unzip -q ${RELEASE}.zip
@ -59,7 +60,6 @@ function update_script() {
msg_ok "Started ${APP}"
msg_info "Cleaning up"
rm -rf /opt/${RELEASE}.zip
rm -rf /opt/linkwarden_bak
msg_ok "Cleaned"
msg_ok "Updated Successfully"
else
@ -75,4 +75,4 @@ description
msg_ok "Completed Successfully!\n"
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
echo -e "${INFO}${YW} Access it using the following URL:${CL}"
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:3000${CL}"
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:3000${CL}"