Skip to content

Commit 4f0c23d

Browse files
yoyo930021claude
andcommitted
feat: scaffold Phase 0 project infrastructure
Backend (Rust): - Initialize Cargo workspace with strict clippy lints - Set up 9 module stubs (auth, core, conversation, ai, tools, email, notifications, storage, audit) - Implement API layer with RFC 7807 ProblemDetails error handling - Add database infrastructure (sqlx pool, migrations, TestContext with postgresql_embedded) - Implement Axum HTTP server with /healthz and /readyz health check endpoints - Add Event Bus (tokio broadcast channel) with DomainEvent enum - Create xtask subproject for future API type generation - Add UUID v7 ID generation utility Frontend (Vue): - Initialize Vite 8 beta (Rolldown) + Vue 3 + TypeScript strict mode - Configure ESLint (oxlint + eslint) with zero warnings policy - Set up openapi-fetch + openapi-typescript for API contract - Create AppLayout and AuthLayout with Vue Router guards - Add base UI components (BaseButton, BaseInput, BaseCard) - Add useAuth composable skeleton Infrastructure: - Add docker-compose.dev.yml (PostgreSQL 16 + MailHog) - Expand Makefile with dev-up, lint, test targets (pnpm) - Add GitHub Actions CI (backend + frontend + OpenAPI validation) - Add .env.example with all environment variables Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 7c9da64 commit 4f0c23d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+9385
-7
lines changed

.cargo/config.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[alias]
2+
xtask = "run --package xtask --"

.env.example

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Database
2+
DATABASE_URL=postgres://confops:devpassword@localhost:5432/confops_dev
3+
DATABASE_MAX_CONNECTIONS=10
4+
DATABASE_MIN_CONNECTIONS=2
5+
6+
# Auth
7+
AUTH_JWT_SECRET=dev-secret-key
8+
AUTH_JWT_ACCESS_EXPIRY=900
9+
AUTH_REFRESH_EXPIRY=604800
10+
AUTH_WEBAUTHN_RP_ID=localhost
11+
AUTH_WEBAUTHN_RP_ORIGIN=http://localhost:3000
12+
13+
# Storage
14+
STORAGE_BACKEND=local
15+
STORAGE_BASE_PATH=./data/files
16+
17+
# Email
18+
SMTP_HOST=localhost
19+
SMTP_PORT=1025
20+
SMTP_USERNAME=
21+
SMTP_PASSWORD=
22+
SMTP_FROM=noreply@localhost
23+
EMAIL_INBOUND_API_KEY=inbound-secret-key
24+
25+
# AI (Google Gemini)
26+
LLM_API_URL=https://generativelanguage.googleapis.com/v1beta
27+
LLM_API_KEY=AIza-dev-key
28+
LLM_MODEL=gemini-2.0-flash
29+
30+
# App
31+
APP_HOST=0.0.0.0
32+
APP_PORT=8080
33+
APP_LOG_LEVEL=debug,confops=trace
34+
APP_CORS_ORIGINS=http://localhost:3000
35+
36+
# WebSocket
37+
WS_HEARTBEAT_INTERVAL=30
38+
WS_MAX_CONNECTIONS=1000

.github/workflows/ci.yml

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main, v2]
6+
pull_request:
7+
branches: [main]
8+
9+
env:
10+
CARGO_TERM_COLOR: always
11+
RUST_BACKTRACE: 1
12+
13+
jobs:
14+
backend:
15+
name: Backend
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- uses: dtolnay/rust-toolchain@stable
21+
with:
22+
components: clippy, rustfmt
23+
24+
- uses: Swatinem/rust-cache@v2
25+
26+
- name: Check formatting
27+
run: cargo fmt -- --check
28+
29+
- name: Clippy
30+
run: cargo clippy -- -D warnings
31+
32+
- name: Run tests
33+
run: cargo test
34+
35+
frontend:
36+
name: Frontend
37+
runs-on: ubuntu-latest
38+
defaults:
39+
run:
40+
working-directory: frontend
41+
steps:
42+
- uses: actions/checkout@v4
43+
44+
- uses: pnpm/action-setup@v4
45+
with:
46+
version: 10
47+
48+
- uses: actions/setup-node@v4
49+
with:
50+
node-version: '22'
51+
cache: 'pnpm'
52+
cache-dependency-path: frontend/pnpm-lock.yaml
53+
54+
- name: Install dependencies
55+
run: pnpm install --frozen-lockfile
56+
57+
- name: Lint
58+
run: pnpm run lint
59+
60+
- name: Type check
61+
run: pnpm run typecheck
62+
63+
- name: Test
64+
run: pnpm run test -- --run
65+
66+
openapi:
67+
name: OpenAPI Spec Validation
68+
runs-on: ubuntu-latest
69+
steps:
70+
- uses: actions/checkout@v4
71+
72+
- uses: actions/setup-node@v4
73+
with:
74+
node-version: '22'
75+
76+
- name: Lint OpenAPI spec
77+
run: npx @redocly/cli lint docs/api/openapi.yaml

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ target/
66
# Node.js
77
node_modules/
88
dist/
9+
.eslintcache
910

1011
# Python
1112
__pycache__/

0 commit comments

Comments
 (0)