mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-03-07 03:15:57 +01:00
wealthfolio: update cors (#12617)
* Update wealthfolio-install.sh * Update wealthfolio.sh
This commit is contained in:
@@ -29,8 +29,11 @@ function update_script() {
|
||||
exit
|
||||
fi
|
||||
|
||||
RELEASE="3.0.3"
|
||||
if check_for_gh_release "wealthfolio" "afadil/wealthfolio" "${RELEASE}"; then
|
||||
if grep -q '^WF_CORS_ALLOW_ORIGINS=\*$' /opt/wealthfolio/.env; then
|
||||
sed -i "s|^WF_CORS_ALLOW_ORIGINS=\*$|WF_CORS_ALLOW_ORIGINS=http://${LOCAL_IP}:8080|" /opt/wealthfolio/.env
|
||||
fi
|
||||
|
||||
if check_for_gh_release "wealthfolio" "afadil/wealthfolio"; then
|
||||
msg_info "Stopping Service"
|
||||
systemctl stop wealthfolio
|
||||
msg_ok "Stopped Service"
|
||||
@@ -40,7 +43,7 @@ function update_script() {
|
||||
cp /opt/wealthfolio/.env /opt/wealthfolio_env_backup
|
||||
msg_ok "Backed up Data"
|
||||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "wealthfolio" "afadil/wealthfolio" "tarball" "v${RELEASE}"
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "wealthfolio" "afadil/wealthfolio" "tarball"
|
||||
|
||||
msg_info "Building Frontend (patience)"
|
||||
cd /opt/wealthfolio
|
||||
|
||||
@@ -51,8 +51,8 @@ WF_DB_PATH=/opt/wealthfolio_data/wealthfolio.db
|
||||
WF_SECRET_KEY=${SECRET_KEY}
|
||||
WF_AUTH_PASSWORD_HASH=${WF_PASSWORD_HASH}
|
||||
WF_STATIC_DIR=/opt/wealthfolio/dist
|
||||
WF_CORS_ALLOW_ORIGINS=*
|
||||
WF_REQUEST_TIMEOUT_MS=30000
|
||||
WF_CORS_ALLOW_ORIGINS=http://${LOCAL_IP}:8080
|
||||
EOF
|
||||
echo "WF_PASSWORD=${WF_PASSWORD}" >~/wealthfolio.creds
|
||||
msg_ok "Configured Wealthfolio"
|
||||
|
||||
Reference in New Issue
Block a user