feat: add coolify deployment and meta tracking

This commit is contained in:
9a0ffedc5b31823b
2026-05-02 22:41:33 +00:00
parent 5c47bdecb6
commit 6b325702b1
13 changed files with 308 additions and 32 deletions

20
tests/deploy.test.ts Normal file
View File

@@ -0,0 +1,20 @@
import { describe, expect, it } from 'vitest';
import { readFileSync } from 'node:fs';
describe('Coolify and Nixpacks deployment config', () => {
it('defines a production start script that binds to all interfaces and PORT', () => {
const packageJson = JSON.parse(readFileSync('package.json', 'utf8'));
expect(packageJson.scripts.start).toContain('astro preview');
expect(packageJson.scripts.start).toContain('--host 0.0.0.0');
expect(packageJson.scripts.start).toContain('${PORT:-4321}');
});
it('pins Nixpacks install, build, and start commands for Coolify', () => {
const nixpacks = readFileSync('nixpacks.toml', 'utf8');
expect(nixpacks).toContain('npm ci');
expect(nixpacks).toContain('npm run build');
expect(nixpacks).toContain('npm run start');
});
});