feat: harden CASAN production install lifecycle

This commit is contained in:
thanhnv
2026-07-24 11:11:44 +07:00
parent c7671ab198
commit 114340c719
48 changed files with 1036 additions and 165 deletions
+13 -1
View File
@@ -16,7 +16,7 @@ ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
cd "$ROOT"
MANIFEST="packaging/levels.json"
VERSION="$(cat VERSION 2>/dev/null || echo 0.0.0)"
DIST="$ROOT/dist"
DIST="${CASAN_DIST_DIR:-$ROOT/dist}"
BUNDLE="${1:-}"
if [[ -z "$BUNDLE" ]]; then
@@ -87,6 +87,18 @@ copy_path() { # <relpath>
fi
local dest="$PKGDIR/$1"
mkdir -p "$(dirname "$dest")"
case "$1" in
packages/casan-harness)
python3 "$ROOT/scripts/copy-runtime.py" \
--source-root "$ROOT" --destination-root "$PKGDIR" --component harness
return
;;
packages/casan-devkit)
python3 "$ROOT/scripts/copy-runtime.py" \
--source-root "$ROOT" --destination-root "$PKGDIR" --component devkit
return
;;
esac
# copy, dropping caches/artifacts
if [[ -d "$src" ]]; then
rsync -a --exclude='__pycache__' --exclude='*.pyc' --exclude='.DS_Store' "$src/" "$dest/" 2>/dev/null \