fix: write deploy script to host filesystem and execute via nsenter
Run Tests / Backend Tests (push) Failing after 2m5s
Run Tests / Frontend Tests (push) Failing after 7m35s
Run Tests / Test Summary (push) Failing after 11m28s

This commit is contained in:
Gan, Jimmy
2026-04-04 11:37:47 +08:00
parent 8e27885ca1
commit d588a48529
+12 -3
View File
@@ -65,6 +65,15 @@ jobs:
- name: Deploy dev
run: |
export DOCKER_API_VERSION=1.43
# Use nsenter with mount and network namespaces to run on host
nsenter -t 1 -m -n /volume1/@appstore/ContainerManager/usr/bin/docker rm -f nas-dashboard-dev || true
nsenter -t 1 -m -n /volume1/@appstore/ContainerManager/usr/bin/docker compose -f /volume1/docker/nas-dashboard/docker-compose.dev.yml up -d --pull never
# Write deploy script to host filesystem
cat > /nas-dashboard/deploy.sh << 'EOF'
#!/bin/bash
set -euo pipefail
export DOCKER_API_VERSION=1.43
cd /volume1/docker/nas-dashboard
/volume1/@appstore/ContainerManager/usr/bin/docker rm -f nas-dashboard-dev || true
/volume1/@appstore/ContainerManager/usr/bin/docker compose -f docker-compose.dev.yml up -d --pull never
EOF
chmod +x /nas-dashboard/deploy.sh
# Execute script on host using nsenter
nsenter -t 1 -m -n /nas-dashboard/deploy.sh