3.0 KiB
3.0 KiB
C0PY — Deployment
SIAX Cloud Deploy
- Config:
siax.config.json - CI/CD:
.gitea/workflows/ci.yml— körs vid push/PR till main (Gitea Actions, git.siax.io) - Runtime: Node 22, port 3000
- Domain:
c0py-web.siax.io(web) /c0py-api.siax.io(API)
Produktion (live 2026-09-16)
| Komponent | Coolify app-uuid | Server | Domän | Image |
|---|---|---|---|---|
| API (Fastify) | wvmn6eg40jofssvm3nigmav6 |
server6 | c0py-api.siax.io |
wvmn6eg40jofssvm3nigmav6:latest |
| Web (Next.js) | 58pa82h4qlzcwsc4shreuwk0 |
server6 | c0py-web.siax.io |
58pa82h4qlzcwsc4shreuwk0:latest |
| Postgres | qhucpjjpv3mx9jupqkbyf5uh |
server6 | — (internt) | — |
- Deploy-mönster: Coolify-appar finns som registry-poster, men bygge sker manuellt på
server6 (
/tmp/c0py-build && docker build -t <app-uuid>:latest .) följt avcd /data/coolify/applications/<app-uuid> && docker compose up -d— Coolifys dockerfile+git-buildpack sätter build-context till helper-container utan repo-trädet och failar för detta monorepo ("/apps": not found). - DNS:
c0py-api+c0py-web= Cloudflare A → 65.109.19.146, DNS-only (proxied=false). Edge-certet täcker bara*.siax.io— tredjenivå-hostnames (api.c0py.siax.io) ger TLS-handshake-failure via proxied; DNS-only låter Traefik LE-certifiera direkt (samma mönster som api.act0.siax.io). - ⚠️ c0py.siax.io (apex) är kapad av en Cloudflare Worker/Pages ("Hello World!", text/plain) utanför vårt token-scope — kan ej avlägsnas utan Workers-perms (Simon-gate).
Deploy via Coolify
- Coolify dashboard:
cloud.siax.io - Resource type: Application (dockerfile build pack, git source git.siax.io/sax3l/c0py)
- Build pack: Dockerfile — API:
/Dockerfile, Web:/Dockerfile.web - ports_exposes:
3000(KRITISKT — default 80 ger Trasfik-labels mot fel port)
Docker
docker build -t siax/c0py .
docker run -d -p 3000:3000 \
-e PORT=3000 \
-e NODE_ENV=production \
-e DATABASE_URL=postgresql://... \
-e CL0UD_BASE_URL=https://cl0ud.siax.io \
-e ZITADEL_ISSUER=https://id-customers.siax.io \
-e ZITADEL_AUDIENCE=c0py-api.siax.io \
-e AUD0_BASE_URL=https://aud0.siax.io \
-e AUD0_API_KEY=... \
-e ST0RE_BASE_URL=https://st0re.siax.io \
siax/c0py
Miljövariabler
| Variable | Krävs | Default | Beskrivning |
|---|---|---|---|
PORT |
Nej | 3000 |
HTTP-serverport |
NODE_ENV |
Nej | development |
Läge |
CL0UD_BASE_URL |
Ja | — | CL0UD kontrollplan URL |
ZITADEL_ISSUER |
Ja | — | OIDC-utfärdare |
ZITADEL_AUDIENCE |
Ja | — | API-audience |
DATABASE_URL |
Ja | — | Postgres-anslutning |
AUD0_BASE_URL |
Nej | — | AUD0 evidens-URL |
AUD0_API_KEY |
Nej | — | AUD0 autentisering |
ST0RE_BASE_URL |
Nej | — | ST0RE lagrings-URL |
INF0_BASE_URL |
Nej | — | INF0 AI-URL |
N0D_BASE_URL |
Nej | — | N0D beräknings-URL |
Hälsocheck
GET /health
Förväntad respons: 200 OK