From 6299d4338f11558659f54dfe5f14343583a214d1 Mon Sep 17 00:00:00 2001 From: Remco <1+remco@noreply.gitlabi@epicnabbo.nl> Date: Sat, 11 Jul 2026 22:09:17 +0200 Subject: [PATCH 1/2] Update .gitea/workflows/deploy.yaml --- .gitea/workflows/deploy.yaml | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml index 0b0f9b97..46284175 100644 --- a/.gitea/workflows/deploy.yaml +++ b/.gitea/workflows/deploy.yaml @@ -11,28 +11,30 @@ jobs: - name: Deploying via SSH connection to VPS Host uses: appleboy/ssh-action@v1.0.3 with: - host: "172.20.2.1" # The default bridge gateway IP pointing back to your VPS host - username: "root" # Replace with your actual VPS SSH username if not running as root + host: "172.20.2.1" + username: "root" key: ${{ secrets.SSH_PRIVATE_KEY }} port: 22 script: | echo "--- Starting EPIC WEB CONTROL Deployment ---" - # 1. Navigate to your project directory on the bare metal VPS + # 1. Navigate to your project directory on the VPS cd /var/www/atom-nexst/ - # [OPTIONEEL] Verwijder of verplaats hier lokale bestanden die NIET in Git staan en in de weg zitten - # rm -rf map-naam/ - # rm -f bestand.txt - # 2. Synchronize the application files via Git git fetch --all git reset --hard origin/main - # [OPTIONEEL] Verwijder of verplaats hier bestanden die zojuist uit Git zijn binnengehaald, vòòr de build - # rm -rf specifieke-map-uit-git/ - # mv bestand-uit-git.json /tmp/ - + # --- CLEAN-UP STEP (After git reset, before build) --- + echo "--- Moving or removing specific items ---" + + # Example: Remove a directory completely + # rm -rf /var/www/atom-nexst/directory-name + + # Example: Move a file to a safe location outside the webroot + # mkdir -p /var/www/atom-storage-temp + # mv /var/www/atom-nexst/config-file.json /var/www/atom-storage-temp/ + # 3. Run database migrations natively echo "--- Running Database Migrations ---" pnpm db:migrate From 627a4d7353ea52230fa64a9c6495c4d0c2c4b613 Mon Sep 17 00:00:00 2001 From: Remco <1+remco@noreply.gitlabi@epicnabbo.nl> Date: Sat, 11 Jul 2026 22:11:02 +0200 Subject: [PATCH 2/2] Update .gitea/workflows/deploy.yaml --- .gitea/workflows/deploy.yaml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml index 46284175..50becef1 100644 --- a/.gitea/workflows/deploy.yaml +++ b/.gitea/workflows/deploy.yaml @@ -27,14 +27,12 @@ jobs: # --- CLEAN-UP STEP (After git reset, before build) --- echo "--- Moving or removing specific items ---" - - # Example: Remove a directory completely # rm -rf /var/www/atom-nexst/directory-name + # mkdir -p /var/www/atom-storage-temp && mv /var/www/atom-nexst/config-file.json /var/www/atom-storage-temp/ - # Example: Move a file to a safe location outside the webroot - # mkdir -p /var/www/atom-storage-temp - # mv /var/www/atom-nexst/config-file.json /var/www/atom-storage-temp/ - + # Load environment variables from .env file for the next steps + export $(grep -v '^#' .env | xargs) + # 3. Run database migrations natively echo "--- Running Database Migrations ---" pnpm db:migrate