feat: restore CI pipelines and add k3s deployment
Re-enable build/test/format pipelines, rename deploy_server to deploy_latest, add upload_tag (tag-triggered k3s deploy) and upload_commit (promote-triggered k3s deploy). Update CLAUDE.md.
This commit is contained in:
11
CLAUDE.md
11
CLAUDE.md
@@ -698,11 +698,18 @@ This uses the `preview` profile from `eas.json` which builds an APK with:
|
||||
|
||||
## CI/CD (Drone)
|
||||
|
||||
The project uses Drone CI (`.drone.yml`) with three pipelines:
|
||||
The project uses Drone CI (`.drone.yml`) with five pipelines:
|
||||
|
||||
**On push to main:**
|
||||
1. **`server_build_and_test`**: Builds the server (`npm ci` + `npm run build`) and runs Jest tests (`npm run test`)
|
||||
2. **`check_for_formatting`**: Checks Prettier formatting across all workspaces (`npm run check_format`)
|
||||
3. **`deploy_server`**: Builds Docker image, pushes to Gitea Container Registry (`gitea.gilmour109.de/Gilmour109/calchat-server`), then SSHs into VPS (`10.0.0.1`) to pull and restart via `docker compose`. Depends on both pipelines above passing first.
|
||||
3. **`deploy_latest`**: Builds Docker image, pushes to Gitea Container Registry (`gitea.gilmour109.de/gilmour109/calchat-server:latest`), then SSHs into VPS (`10.0.0.1`) to pull and restart via `docker compose`. Depends on both pipelines above passing first.
|
||||
|
||||
**On tag:**
|
||||
4. **`upload_tag`**: Builds Docker image tagged with the git tag (`${DRONE_TAG}`), pushes to registry, then deploys to k3s cluster (`192.168.178.201`) via SSH using `envsubst` with a Kubernetes manifest template.
|
||||
|
||||
**On promote:**
|
||||
5. **`upload_commit`**: Builds Docker image tagged with short commit SHA (first 8 chars), pushes to registry, then deploys to k3s cluster (`192.168.178.201`) via SSH using `envsubst` with a Kubernetes manifest template.
|
||||
|
||||
## Testing
|
||||
|
||||
|
||||
Reference in New Issue
Block a user