Compare commits

..

2 Commits

2 changed files with 14 additions and 2 deletions
+12 -1
View File
@@ -154,9 +154,16 @@ EOF
/opt/termix/nginx \
/opt/termix/nginx/logs \
/opt/termix/nginx/cache \
/opt/termix/nginx/client_body
/opt/termix/nginx/client_body \
/opt/termix/db/data
msg_ok "Recreated Directories"
if [[ -f /opt/termix/data/db.sqlite.encrypted && ! -f /opt/termix/db/data/db.sqlite.encrypted ]]; then
msg_info "Migrating Database to new layout"
cp -a /opt/termix/data/db.sqlite.encrypted /opt/termix/db/data/db.sqlite.encrypted
msg_ok "Migrated Database to new layout"
fi
msg_info "Building Frontend"
cd /opt/termix
export COREPACK_ENABLE_DOWNLOAD_PROMPT=0
@@ -168,6 +175,10 @@ EOF
msg_info "Building Backend"
$STD npm rebuild better-sqlite3 --force
$STD npm run build:backend
if [[ ! -f /opt/termix/dist/backend/backend/starter.js ]]; then
msg_error "Backend build failed: /opt/termix/dist/backend/backend/starter.js was not created"
exit 1
fi
msg_ok "Built Backend"
msg_info "Setting up Production Dependencies"
+2 -1
View File
@@ -85,7 +85,8 @@ mkdir -p /opt/termix/data \
/opt/termix/nginx \
/opt/termix/nginx/logs \
/opt/termix/nginx/cache \
/opt/termix/nginx/client_body
/opt/termix/nginx/client_body \
/opt/termix/db/data
cp -r /opt/termix/dist/* /opt/termix/html/ 2>/dev/null || true
cp -r /opt/termix/src/locales /opt/termix/html/locales 2>/dev/null || true