Build and Deploy Documentation / build (push) Failing after 9s
Styling: - Tailwind CSS v4 (preflight:false) integrated via PostCSS plugin - shadcn/ui New York style with --radius:0 (sharp corners everywhere) - Zero border-radius on ALL elements: buttons, code blocks, cards, admonitions, badges - Navbar FORCE dark (#0a0a0a) in both light/dark modes via !important - ThemeSynchronizer: bridges Docusaurus data-theme → shadcn .dark class - Active sidebar item gets left border accent instead of rounded bg React UI components (src/components/ui/index.tsx): - Badge (6 variants: wip, stable, planned, success, warning, outline) - Card + CardHeader + CardTitle + CardContent - Callout (note/info/success/warning/danger) - sharp, left-border style - PropertiesTable - monospace typed API reference tables - StatusIndicator - operational/degraded/outage/maintenance Navigation restructure: - Introduction → Platform → Products → Engineering → Runbooks - Old 'applications/' removed, moved to products/stock-market-pro/ - New Platform section: infrastructure overview + CI/CD pipeline docs - New Engineering section: monorepo structure, Go stack, conventions - New Runbooks section: incident severity, common procedures Implementation guidelines (engineering/guidelines.md): - Monorepo layout with go.work workspace - Go as primary language (why + standard library table) - Python as sidecar for data/ML workloads - Code conventions: gofmt, error wrapping, logging, testing - Git conventions: branch naming, conventional commits - Makefile targets per app - How to add a new application (step-by-step)
66 lines
1.4 KiB
Markdown
66 lines
1.4 KiB
Markdown
---
|
|
sidebar_position: 2
|
|
---
|
|
|
|
# CI/CD Pipeline
|
|
|
|
All applications follow a single, consistent Gitea Actions pipeline.
|
|
|
|
## Flow
|
|
|
|
```mermaid
|
|
sequenceDiagram
|
|
participant J as Jarvis / Dev
|
|
participant G as Gitea
|
|
participant A as Actions Worker
|
|
participant R as Zot Registry
|
|
participant H as TrueNAS Host
|
|
|
|
J->>G: git push main
|
|
G->>A: Trigger workflow
|
|
A->>A: pnpm/go build + test
|
|
A->>R: docker push image
|
|
A->>H: Deploy (restart container)
|
|
H-->>J: ✅ Live
|
|
```
|
|
|
|
## Workflow Template
|
|
|
|
```yaml
|
|
# .gitea/workflows/build.yml
|
|
name: Build and Deploy
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Build
|
|
run: make build # or go build / pnpm build
|
|
|
|
- name: Test
|
|
run: make test
|
|
|
|
- name: Docker build & push
|
|
if: github.ref == 'refs/heads/main'
|
|
run: |
|
|
docker build -t $ZOT_REGISTRY/$APP_NAME:$GITHUB_SHA .
|
|
docker push $ZOT_REGISTRY/$APP_NAME:$GITHUB_SHA
|
|
|
|
- name: Deploy
|
|
if: github.ref == 'refs/heads/main'
|
|
run: |
|
|
ssh deploy@lego-cloud.eu "docker pull && docker restart $APP_NAME"
|
|
```
|
|
|
|
## Gitea Actions Runners
|
|
|
|
Runners need to be registered on the Gitea instance. See [Gitea Actions documentation](https://docs.gitea.com/usage/actions/quickstart) for setup.
|