I’m trying to set up 3 sites on the same server for production, staging, and dev synced with corresponding Github branches of the same repo.
I can get the main branch up without issue. But any other branch fails on Activate New Deployment with this type of error:
Activate New Deployment 20220513020507912
Activated /home/cleavr/zmcfuwmmvbmk25b43466.cleaver.rocks/releases/20220513020507912/dist/ssr
PM2 ecosystem file is not linked. Linking...
PM2 ecosystem config hasn't changed since the last deployment. Reloading the app...
[PM2] Applying action reloadProcessId on app [zmcfuwmmvbmk25b43466.cleaver.rocks](ids: [ 60 ])
[PM2] [zmcfuwmmvbmk25b43466.cleaver.rocks](60) ✓
┌─────┬───────────────────────────────────────┬─────────────┬─────────┬─────────┬──────────┬────────┬──────┬───────────┬──────────┬──────────┬──────────┬──────────┐
│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │
├─────┼───────────────────────────────────────┼─────────────┼─────────┼─────────┼──────────┼────────┼──────┼───────────┼──────────┼──────────┼──────────┼──────────┤
│ 56 │ k7tmyepoiuiwmyn23466.cleaver.rocks │ default │ 0.0.1 │ cluster │ 1467427 │ 4m │ 32 │ online │ 0.3% │ 7.2mb │ cleavr │ disabled │
│ 60 │ zmcfuwmmvbmk25b43466.cleaver.rocks │ default │ 0.0.1 │ cluster │ 1468766 │ 0s │ 16 │ online │ 0% │ 37.4mb │ cleavr │ disabled │
└─────┴───────────────────────────────────────┴─────────────┴─────────┴─────────┴──────────┴────────┴──────┴───────────┴──────────┴──────────┴──────────┴──────────┘
Force restarting the app
[PM2] Applying action deleteProcessId on app [zmcfuwmmvbmk25b43466.cleaver.rocks](ids: [ 60 ])
[PM2] [zmcfuwmmvbmk25b43466.cleaver.rocks](60) ✓
┌─────┬───────────────────────────────────────┬─────────────┬─────────┬─────────┬──────────┬────────┬──────┬───────────┬──────────┬──────────┬──────────┬──────────┐
│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │
├─────┼───────────────────────────────────────┼─────────────┼─────────┼─────────┼──────────┼────────┼──────┼───────────┼──────────┼──────────┼──────────┼──────────┤
│ 56 │ k7tmyepoiuiwmyn23466.cleaver.rocks │ default │ 0.0.1 │ cluster │ 1467427 │ 4m │ 32 │ online │ 0% │ 7.5mb │ cleavr │ disabled │
└─────┴───────────────────────────────────────┴─────────────┴─────────┴─────────┴──────────┴────────┴──────┴───────────┴──────────┴──────────┴──────────┴──────────┘
[PM2][WARN] Current process list is not synchronized with saved list. App zmcfuwmmvbmk25b43466.cleaver.rocks differs. Type 'pm2 save' to synchronize.
[PM2][WARN] Applications zmcfuwmmvbmk25b43466.cleaver.rocks not running, starting...
[PM2][ERROR] Error: Script not found: /home/cleavr/zmcfuwmmvbmk25b43466.cleaver.rocks/current/index.js
k7tmyepoiuiwmyn23466.cleaver.rocks is the “main” branch that works as expected.
zmcfuwmmvbmk25b43466.cleaver.rocks is set up to follow the “stage” branch on the repo.
I understand Cleavr has a staging feature that syncs files from one site to another. My motivation here is to leverage separate code bases with pull requests as a means to update dev, stage, and prod sites.
Any suggestions as to where I took a wrong turn? Or should I be using the Staging/Sync option with one single repo branch?
Many Thanks…