mirror of
https://codeberg.org/PostERG/xamxam.git
synced 2026-11-09 19:20:09 +01:00
feat(deploy): add deploy-verify-permissions recipe + upload/run deploy-server.sh before verification + run migrations in deploy
This commit is contained in:
1 parent
3136fa7113
commit
72f7192156
8 files changed
+5290
-444
No files matched your search
+12
-3
@@ -7,9 +7,18 @@
|
||||
set -euo pipefail
|
||||
|
||||
REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
|
||||
APP_DIR="$REPO_ROOT/app"
|
||||
SCHEMA="$APP_DIR/storage/schema.sql"
|
||||
PROD_DB="$APP_DIR/storage/xamxam.db"
|
||||
|
||||
# Detect layout: local dev has app/ subdir, server has files at repo root
|
||||
if [ -d "$REPO_ROOT/app/storage" ]; then
|
||||
SCHEMA="$REPO_ROOT/app/storage/schema.sql"
|
||||
PROD_DB="$REPO_ROOT/app/storage/xamxam.db"
|
||||
elif [ -f "$REPO_ROOT/storage/schema.sql" ]; then
|
||||
SCHEMA="$REPO_ROOT/storage/schema.sql"
|
||||
PROD_DB="$REPO_ROOT/storage/xamxam.db"
|
||||
else
|
||||
echo "ERROR: cannot find storage/schema.sql" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
init_db() {
|
||||
local db="$1"
|
||||
|
||||
Reference in new issue
Block a user