Add complete NexaFabric project structure including: - FastAPI backend with SQLAlchemy models, JWT auth, RBAC, audit logging, and provider interfaces - React + TypeScript frontend with Vite, Tailwind CSS, TanStack Query, and Zustand - Docker Compose configuration for PostgreSQL, Redis, API, worker, frontend, and nginx - GitHub Actions and GitLab CI workflows for testing, linting, building, and security scanning - Environment
1.1 KiB
1.1 KiB
Architecture
NexaFabric is split into five layers:
- Frontend: React application for daily network, IPAM, policy, and audit operations.
- API: FastAPI REST surface with OpenAPI docs, JWT auth, RBAC hooks, and validation.
- Domain services: provider registry, policy engine, firewall orchestrator, audit service, and job coordination.
- Persistence: PostgreSQL through SQLAlchemy models. Alembic is intended for production migrations.
- Workers: background execution for sync, compile, drift detection, IPAM scans, cleanup, and backup export.
Provider interfaces are intentionally separated into HypervisorProvider, InventoryProvider, NetworkProvider, and FirewallProvider. The first implementation is Proxmox, but the API layer is not tied directly to Proxmox-specific code.
Firewall orchestration follows this flow:
- Policy definition is compiled.
- Conflicts and broad access warnings are calculated.
- Provider-specific preview output is produced.
- Audit log records the preview.
- A later apply path must verify cluster write mode, acquire a lock, and write a second audit record.