diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml deleted file mode 100644 index d6f10a7..0000000 --- a/.gitea/workflows/deploy.yaml +++ /dev/null @@ -1,43 +0,0 @@ -name: Deploy To Dev - -on: - push: - branches: - - 'dev' - -jobs: - deploy: - runs-on: gx-dev01 - - steps: - - name: Checkout code - uses: actions/checkout@v4 - - - name: Copy specific directory to runner's host machine - run: | - TARGET_DIR="./dist" - - # 检查 dist 目录是否存在 - if [ ! -d "$TARGET_DIR" ]; then - echo "Error: The source directory '$TARGET_DIR' does not exist in the repository." - # 如果目录不存在,报错并退出当前步骤 - exit 1 - fi - cp -r ./dist/* /data/xsy-www/ - - - name: Find and restart the app container - run: | - # 1. 使用 docker ps 过滤包含 'xsy-lighttpd' 服务的容器 - # 2. 提取容器 ID 或名称 - CONTAINER_ID=$(docker ps -a --filter "name=xsy-lighttpd" --format "{{.ID}}") - - if [ -z "$CONTAINER_ID" ]; then - echo "Error: Could not find any container matching name 'app1'." - exit 1 - else - echo "Found container ID: $CONTAINER_ID. Restarting..." - # 使用标准的 docker restart 命令 - docker restart "$CONTAINER_ID" - echo "Container restarted successfully." - fi - diff --git a/.gitignore b/.gitignore index d08d8f6..8680825 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,7 @@ lerna-debug.log* node_modules .DS_Store +dist dist-ssr coverage *.local