Apply Composer changes: comprehensive API updates, migrations, middleware, and infrastructure improvements

- Add comprehensive database migrations (001-024) for schema evolution
- Enhance API schema with expanded type definitions and resolvers
- Add new middleware: audit logging, rate limiting, MFA enforcement, security, tenant auth
- Implement new services: AI optimization, billing, blockchain, compliance, marketplace
- Add adapter layer for cloud integrations (Cloudflare, Kubernetes, Proxmox, storage)
- Update Crossplane provider with enhanced VM management capabilities
- Add comprehensive test suite for API endpoints and services
- Update frontend components with improved GraphQL subscriptions and real-time updates
- Enhance security configurations and headers (CSP, CORS, etc.)
- Update documentation and configuration files
- Add new CI/CD workflows and validation scripts
- Implement design system improvements and UI enhancements
This commit is contained in:
defiQUG
2025-12-12 18:01:35 -08:00
parent e01131efaf
commit 9daf1fd378
968 changed files with 160890 additions and 1092 deletions

View File

@@ -1,4 +1,4 @@
name: CI
name: CI Pipeline
on:
push:
@@ -7,108 +7,194 @@ on:
branches: [main, develop]
jobs:
lint:
name: Lint
lint-and-type-check:
name: Lint and Type Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- run: pnpm lint
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Lint frontend
run: pnpm lint
- name: Type check frontend
run: pnpm type-check
- name: Lint API
working-directory: ./api
run: pnpm type-check
- name: Lint Portal
working-directory: ./portal
run: pnpm type-check
type-check:
name: Type Check
test-backend:
name: Test Backend
runs-on: ubuntu-latest
services:
postgres:
image: postgres:14-alpine
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: sankofa_test
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- run: pnpm type-check
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- name: Install dependencies
working-directory: ./api
run: pnpm install --frozen-lockfile
- name: Run database migrations
working-directory: ./api
env:
DB_HOST: localhost
DB_PORT: 5432
DB_NAME: sankofa_test
DB_USER: postgres
DB_PASSWORD: postgres
run: pnpm db:migrate:up
- name: Run tests
working-directory: ./api
env:
DB_HOST: localhost
DB_PORT: 5432
DB_NAME: sankofa_test
DB_USER: postgres
DB_PASSWORD: postgres
run: pnpm test
- name: Generate coverage report
working-directory: ./api
run: pnpm test:coverage
- name: Upload coverage
uses: codecov/codecov-action@v3
with:
files: ./api/coverage/coverage-final.json
flags: backend
format-check:
name: Format Check
test-frontend:
name: Test Frontend
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- run: pnpm format:check
test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- run: pnpm test --run
- uses: codecov/codecov-action@v3
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Run tests
run: pnpm test
- name: Generate coverage report
run: pnpm test:coverage
- name: Upload coverage
uses: codecov/codecov-action@v3
with:
files: ./coverage/coverage-final.json
flags: unittests
name: codecov-umbrella
flags: frontend
build:
name: Build
runs-on: ubuntu-latest
needs: [lint-and-type-check]
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- run: pnpm build
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build API
working-directory: ./api
run: pnpm build
- name: Build Frontend
run: pnpm build
- name: Build Portal
working-directory: ./portal
run: pnpm build
- name: Upload build artifacts
uses: actions/upload-artifact@v3
with:
name: build
path: .next
name: build-artifacts
path: |
api/dist
.next
portal/.next
accessibility:
name: Accessibility Check
security-scan:
name: Security Scan
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@master
with:
version: 8
- uses: actions/setup-node@v4
scan-type: 'fs'
scan-ref: '.'
format: 'sarif'
output: 'trivy-results.sarif'
- name: Upload Trivy results
uses: github/codeql-action/upload-sarif@v2
with:
node-version: '20'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- name: Run accessibility tests
run: |
# Install pa11y or similar accessibility testing tool
npm install -g @pa11y/pa11y-ci
# Run accessibility checks (requires built app)
echo "Accessibility checks would run here after build"
sarif_file: 'trivy-results.sarif'