diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml deleted file mode 100644 index 1d3b585f..00000000 --- a/.gitea/workflows/deploy.yaml +++ /dev/null @@ -1,49 +0,0 @@ -name: Remote Build and Deploy -on: - push: - branches: - - main - -jobs: - deploy: - runs-on: ubuntu-latest - steps: - - name: Deploying via SSH connection to VPS Host - uses: appleboy/ssh-action@v1.0.3 - # We koppelen de secrets hier aan env-variabelen voor maximale betrouwbaarheid - env: - HOST_IP: ${{ secrets.VPS_HOST }} - SSH_KEY: ${{ secrets.SSH_PRIVATE_KEY }} - with: - host: ${{ env.HOST_IP }} - username: "root" - key: ${{ env.SSH_KEY }} - port: 22 - # 'set -e' zorgt voor 100% stop bij falen, beschermt je server - script: | - set -e - echo "--- Starting EPIC WEB CONTROL Deployment ---" - - cd /var/www/atom-nexst/ - - # 1. Veilige update - git fetch origin --prune - git reset --hard origin/main - - # 2. Cleanup (met check om crashen te voorkomen) - if [ -d "directory-name" ]; then rm -rf directory-name; fi - - # 3. Dependencies - # Gebruik het volledige pad naar pnpm voor zekerheid - # (Controleer 'which pnpm' op je server als dit pad afwijkt) - /usr/local/bin/pnpm install --frozen-lockfile - - # 4. Database en Types - /usr/local/bin/pnpm db:migrate - /usr/local/bin/pnpm prisma generate - - # 5. Build en Restart - /usr/local/bin/pnpm build - sudo systemctl restart atom-nexst.service - - echo "--- EPIC WEB CONTROL Deployment Completed Successfully ---" \ No newline at end of file