chore: seal Design Vision v1 and monorepo scaffold
Archive the differentiated YuXinGu product docs, AI engineering system, design contract, and Go/Vue scaffold. Next execution prioritizes Cece-parity over early innovation (see .ai/product/STRATEGY.md). Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
# Deployment — Golden Rules
|
||||
|
||||
## Containers
|
||||
|
||||
- Every runnable service that ships to prod must have a Dockerfile.
|
||||
- Never use image tag `latest` in production.
|
||||
- Always semantic version tags: `v0.1.0` or git SHA.
|
||||
|
||||
## Health
|
||||
|
||||
- Liveness: `GET /api/v1/healthz` required.
|
||||
- When DB is required for traffic: add readiness endpoint (e.g. `/api/v1/readyz`) that checks DB.
|
||||
- Alias names `/health` `/readiness` `/liveness` may map to the above; keep one canonical path documented in OpenAPI.
|
||||
|
||||
## Config
|
||||
|
||||
- Secrets via env only. Commit `.env.example`, never `.env`.
|
||||
- Required: `APP_ENV`, `HTTP_ADDR`, `DATABASE_URL`.
|
||||
|
||||
## CI
|
||||
|
||||
- No manual prod deploy as the happy path — CI builds and tags.
|
||||
- Minimum gates: `go test ./...` (api), `npm run build:h5`.
|
||||
|
||||
## Local
|
||||
|
||||
```bash
|
||||
docker compose -f deploy/docker-compose.yml up -d
|
||||
cd apps/api && go run ./cmd/server
|
||||
npm run dev:h5
|
||||
```
|
||||
|
||||
If Go module download times out in CN: `export GOPROXY=https://goproxy.cn,direct`.
|
||||
Reference in New Issue
Block a user