Changeset 834bcc3 in Klonkt for src/routes/admin-updates.js
- Timestamp:
- 06/23/2026 06:14:27 PM (3 months ago)
- Branches:
- main
- Children:
- d774679
- Parents:
- bb42dfb
- File:
-
- 1 edited
-
src/routes/admin-updates.js (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/routes/admin-updates.js
rbb42dfb r834bcc3 1 1 /** 2 2 * Admin: Updates (god-only). 3 * Git- gebaseerde v1 voor instances die via de bare-repo draaien.4 * GET /admin/updates -> huidige vs. nieuwste versie+ status5 * POST /admin/updates/run -> haal nieuwste main op + herstart (detached script)3 * Git-based v1 for instances running from a bare repo. 4 * GET /admin/updates -> current vs. latest version + status 5 * POST /admin/updates/run -> fetch latest main + restart (detached script) 6 6 * 7 * De instance kent z'n "huidige" commit uit .klonkt-version (door het script8 * geschreven) en de "nieuwste" uit de bare repo (KLONKT_GIT_DIR). Voor externe9 * self-hosters komt later een GESIGNEERDE release-feed (zie monetization-plan);10 * deze v1 is bewust simpel en alleen voor Robins eigen VPS-instances.7 * The instance knows its "current" commit from .klonkt-version (written by the 8 * script) and the "latest" from the bare repo (KLONKT_GIT_DIR). For external 9 * self-hosters a SIGNED release feed will follow later (see monetization plan); 10 * this v1 is intentionally simple and only for Robin's own VPS instances. 11 11 */ 12 12 … … 37 37 } 38 38 39 // La atste 5 commits op main = de "laatste wijzigingen" die je bij bijwerken krijgt.39 // Last 5 commits on main = the "recent changes" you'll get when updating. 40 40 function recentChanges() { 41 41 const out = git(['log', '-5', '--format=%s%x1f%cd', '--date=short', 'main']); … … 72 72 } 73 73 try { 74 // Detached + losgekoppeld: overleeft de pm2-reload die deze app herstart.74 // Detached + unlinked: survives the pm2-reload that restarts this app. 75 75 const child = spawn('bash', [UPDATE_SCRIPT, process.cwd()], { detached: true, stdio: 'ignore' }); 76 76 child.unref();
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)