mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-09-25 21:57:15 +02:00
Journiv: Serve Node Frontend and add HTTP Auth .env (#17479)
* Let Journiv start over plain HTTP * Build the Journiv frontend * Return to the project root before alembic
This commit is contained in:
committed by
GitHub
parent
26c3bb9325
commit
037e55256c
@@ -45,6 +45,17 @@ function update_script() {
|
|||||||
$STD uv sync --locked --no-editable --no-install-project
|
$STD uv sync --locked --no-editable --no-install-project
|
||||||
msg_ok "Updated Python Environment"
|
msg_ok "Updated Python Environment"
|
||||||
|
|
||||||
|
NODE_VERSION="24" setup_nodejs
|
||||||
|
msg_info "Building Frontend"
|
||||||
|
cd /opt/journiv/frontend
|
||||||
|
$STD npm ci
|
||||||
|
$STD npm run build
|
||||||
|
cd /opt/journiv
|
||||||
|
msg_ok "Built Frontend"
|
||||||
|
|
||||||
|
grep -q '^ALLOW_INSECURE_COOKIE_AUTH_OVER_HTTP=' /opt/journiv.env ||
|
||||||
|
echo 'ALLOW_INSECURE_COOKIE_AUTH_OVER_HTTP=true' >>/opt/journiv.env
|
||||||
|
|
||||||
msg_info "Running Database Migrations"
|
msg_info "Running Database Migrations"
|
||||||
set -a
|
set -a
|
||||||
source /opt/journiv.env
|
source /opt/journiv.env
|
||||||
|
|||||||
@@ -53,11 +53,21 @@ EXPORT_DIR=/opt/journiv_data/exports
|
|||||||
IMPORT_TEMP_DIR=/opt/journiv_data/imports/temp
|
IMPORT_TEMP_DIR=/opt/journiv_data/imports/temp
|
||||||
DOMAIN_NAME=${LOCAL_IP}
|
DOMAIN_NAME=${LOCAL_IP}
|
||||||
DOMAIN_SCHEME=http
|
DOMAIN_SCHEME=http
|
||||||
|
# Journiv refuses to start on plain HTTP without this.
|
||||||
|
ALLOW_INSECURE_COOKIE_AUTH_OVER_HTTP=true
|
||||||
PYTHONPATH=/opt/journiv
|
PYTHONPATH=/opt/journiv
|
||||||
EOF
|
EOF
|
||||||
chmod 600 /opt/journiv.env
|
chmod 600 /opt/journiv.env
|
||||||
msg_ok "Configured Journiv"
|
msg_ok "Configured Journiv"
|
||||||
|
|
||||||
|
NODE_VERSION="24" setup_nodejs
|
||||||
|
msg_info "Building Frontend"
|
||||||
|
cd /opt/journiv/frontend
|
||||||
|
$STD npm ci
|
||||||
|
$STD npm run build
|
||||||
|
cd /opt/journiv
|
||||||
|
msg_ok "Built Frontend"
|
||||||
|
|
||||||
msg_info "Initializing Database"
|
msg_info "Initializing Database"
|
||||||
set -a
|
set -a
|
||||||
source /opt/journiv.env
|
source /opt/journiv.env
|
||||||
|
|||||||
Reference in New Issue
Block a user