agentic-dev 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agent/prd.json +29 -0
- package/.agent/progress.txt +1 -0
- package/.agent/prompt.md +21 -0
- package/.agent/ralph-loop-state.json +13 -0
- package/.agent/ralph-supervisor-state.json +12 -0
- package/.agent/ralph-supervisor.sh +238 -0
- package/.agent/ralph.sh +305 -0
- package/.agent/runs/README.md +7 -0
- package/.agent/sdd-build-ast-audit.json +13 -0
- package/.claude/CLAUDE.md +44 -0
- package/.claude/agentic-dev.json +3 -0
- package/.claude/agents/ai-dev.md +27 -0
- package/.claude/agents/backend-dev.md +26 -0
- package/.claude/agents/db-dev.md +26 -0
- package/.claude/agents/devops.md +27 -0
- package/.claude/agents/frontend-dev.md +25 -0
- package/.claude/agents/github-ops.md +25 -0
- package/.claude/agents/test-dev.md +26 -0
- package/.claude/agents/uiux-designer.md +25 -0
- package/.claude/settings.json +49 -0
- package/.claude/settings.local.json +8 -0
- package/.claude/skills/commit/SKILL.md +37 -0
- package/.claude/skills/dev-browser/SKILL.md +30 -0
- package/.claude/skills/otro/SKILL.md +43 -0
- package/.claude/skills/planning-with-files/SKILL.md +37 -0
- package/.claude/skills/prd/SKILL.md +27 -0
- package/.claude/skills/ralph-loop/SKILL.md +42 -0
- package/.claude/skills/sdd/SKILL.md +13 -0
- package/.claude/skills/sdd-dev/SKILL.md +71 -0
- package/.claude/skills/sdd-development/SKILL.md +13 -0
- package/.claude/workspace-config.json +3 -0
- package/.codex/agentic-dev.json +3 -0
- package/.codex/agents/README.md +22 -0
- package/.codex/agents/api.toml +11 -0
- package/.codex/agents/architecture.toml +11 -0
- package/.codex/agents/ci.toml +11 -0
- package/.codex/agents/gitops.toml +11 -0
- package/.codex/agents/orchestrator.toml +11 -0
- package/.codex/agents/quality.toml +11 -0
- package/.codex/agents/runtime.toml +11 -0
- package/.codex/agents/security.toml +11 -0
- package/.codex/agents/specs.toml +11 -0
- package/.codex/agents/ui.toml +11 -0
- package/.codex/config.toml +46 -0
- package/.codex/skills/SKILL.md +13 -0
- package/.codex/skills/agents/openai.yaml +4 -0
- package/.codex/skills/commit/SKILL.md +219 -0
- package/.codex/skills/commit/references/commit_examples.md +292 -0
- package/.codex/skills/dev-browser/SKILL.md +211 -0
- package/.codex/skills/dev-browser/bun.lock +443 -0
- package/.codex/skills/dev-browser/package-lock.json +2988 -0
- package/.codex/skills/dev-browser/package.json +31 -0
- package/.codex/skills/dev-browser/references/scraping.md +155 -0
- package/.codex/skills/dev-browser/scripts/start-relay.ts +32 -0
- package/.codex/skills/dev-browser/scripts/start-server.ts +117 -0
- package/.codex/skills/dev-browser/server.sh +24 -0
- package/.codex/skills/dev-browser/src/client.ts +474 -0
- package/.codex/skills/dev-browser/src/index.ts +287 -0
- package/.codex/skills/dev-browser/src/relay.ts +731 -0
- package/.codex/skills/dev-browser/src/snapshot/__tests__/snapshot.test.ts +223 -0
- package/.codex/skills/dev-browser/src/snapshot/browser-script.ts +877 -0
- package/.codex/skills/dev-browser/src/snapshot/index.ts +14 -0
- package/.codex/skills/dev-browser/src/snapshot/inject.ts +13 -0
- package/.codex/skills/dev-browser/src/types.ts +34 -0
- package/.codex/skills/dev-browser/tsconfig.json +36 -0
- package/.codex/skills/dev-browser/vitest.config.ts +12 -0
- package/.codex/skills/otro/SKILL.md +74 -0
- package/.codex/skills/otro/agents/openai.yaml +4 -0
- package/.codex/skills/otro/references/agent-prompts.md +61 -0
- package/.codex/skills/otro/references/contracts.md +146 -0
- package/.codex/skills/otro/references/orchestration-loop.md +51 -0
- package/.codex/skills/otro/references/runtime.md +79 -0
- package/.codex/skills/otro/runs/README.md +11 -0
- package/.codex/skills/otro/schemas/step_plan.schema.json +289 -0
- package/.codex/skills/otro/schemas/task_result.schema.json +142 -0
- package/.codex/skills/otro/schemas/wave_plan.schema.json +4 -0
- package/.codex/skills/otro/scripts/README.md +38 -0
- package/.codex/skills/otro/scripts/bump_validation_header.py +179 -0
- package/.codex/skills/otro/scripts/check_validation_header.py +84 -0
- package/.codex/skills/otro/scripts/common.py +303 -0
- package/.codex/skills/otro/scripts/init_run.sh +68 -0
- package/.codex/skills/otro/scripts/plan_loop.py +8 -0
- package/.codex/skills/otro/scripts/plan_step.py +367 -0
- package/.codex/skills/otro/scripts/plan_wave.py +8 -0
- package/.codex/skills/otro/scripts/reconcile_loop.py +8 -0
- package/.codex/skills/otro/scripts/reconcile_step.py +37 -0
- package/.codex/skills/otro/scripts/reconcile_wave.py +8 -0
- package/.codex/skills/otro/scripts/run_loop.py +300 -0
- package/.codex/skills/otro/scripts/run_loop_step.py +8 -0
- package/.codex/skills/otro/scripts/run_step.py +246 -0
- package/.codex/skills/otro/scripts/run_wave.py +8 -0
- package/.codex/skills/otro/validation/validation.md +15 -0
- package/.codex/skills/planning-with-files/SKILL.md +42 -0
- package/.codex/skills/planning-with-files/agents/openai.yaml +4 -0
- package/.codex/skills/planning-with-files/assets/plan-template.md +37 -0
- package/.codex/skills/planning-with-files/references/plan-rules.md +35 -0
- package/.codex/skills/planning-with-files/scripts/new_plan.sh +65 -0
- package/.codex/skills/prd/SKILL.md +235 -0
- package/.codex/skills/ralph-loop/SKILL.md +46 -0
- package/.codex/skills/ralph-loop/agents/openai.yaml +4 -0
- package/.codex/skills/ralph-loop/references/failure-triage.md +32 -0
- package/.codex/skills/ralph-loop/scripts/loop_until_success.sh +97 -0
- package/.codex/skills/sdd/SKILL.md +184 -0
- package/.codex/skills/sdd/agents/openai.yaml +4 -0
- package/.codex/skills/sdd/references/section-map.md +67 -0
- package/.dockerignore +8 -0
- package/.env.example +50 -0
- package/.gitignore +16 -0
- package/AGENTS.md +78 -0
- package/README.md +83 -47
- package/SDD_SKILL.md +589 -0
- package/bin/agentic-dev.mjs +97 -0
- package/client/admin/.dockerignore +3 -0
- package/client/admin/.env.example +1 -0
- package/client/admin/Dockerfile +16 -0
- package/client/admin/Dockerfile.dev +18 -0
- package/client/admin/README.md +20 -0
- package/client/admin/index.html +12 -0
- package/client/admin/package.json +41 -0
- package/client/admin/postcss.config.js +6 -0
- package/client/admin/scripts/ui-parity-admin-adapter.mjs +65 -0
- package/client/admin/src/api/alerts.ts +33 -0
- package/client/admin/src/api/client.ts +71 -0
- package/client/admin/src/api/orders.ts +33 -0
- package/client/admin/src/api/support.ts +11 -0
- package/client/admin/src/app/App.tsx +23 -0
- package/client/admin/src/auth/AuthProvider.tsx +122 -0
- package/client/admin/src/auth/ProtectedRoute.tsx +22 -0
- package/client/admin/src/auth/auth-client.ts +38 -0
- package/client/admin/src/auth/types.ts +18 -0
- package/client/admin/src/components/AdminNotificationsDrawer.tsx +162 -0
- package/client/admin/src/components/AdminShell.tsx +76 -0
- package/client/admin/src/components/ui/button.tsx +34 -0
- package/client/admin/src/components/ui/input.tsx +21 -0
- package/client/admin/src/lib/cn.ts +6 -0
- package/client/admin/src/lib/specRouteCatalog.json +30 -0
- package/client/admin/src/lib/specScreens.json +22 -0
- package/client/admin/src/main.tsx +17 -0
- package/client/admin/src/pages/AdminDashboardPage.tsx +171 -0
- package/client/admin/src/pages/AdminLoginPage.tsx +75 -0
- package/client/admin/src/pages/AdminQueuePage.tsx +107 -0
- package/client/admin/src/pages/AdminSupportPage.tsx +61 -0
- package/client/admin/src/styles/globals.css +17 -0
- package/client/admin/src/theme-vars.ts +18 -0
- package/client/admin/src/theme.ts +25 -0
- package/client/admin/src/vite-env.d.ts +1 -0
- package/client/admin/tailwind.config.js +8 -0
- package/client/admin/tsconfig.json +25 -0
- package/client/admin/vite.config.ts +12 -0
- package/client/landing/.dockerignore +3 -0
- package/client/landing/.env.example +1 -0
- package/client/landing/Dockerfile +16 -0
- package/client/landing/Dockerfile.dev +18 -0
- package/client/landing/README.md +18 -0
- package/client/landing/index.html +12 -0
- package/client/landing/package.json +41 -0
- package/client/landing/postcss.config.js +6 -0
- package/client/landing/scripts/ui-parity-landing-adapter.mjs +65 -0
- package/client/landing/src/App.tsx +21 -0
- package/client/landing/src/api/catalog.ts +30 -0
- package/client/landing/src/api/client.ts +30 -0
- package/client/landing/src/auth/AuthProvider.tsx +122 -0
- package/client/landing/src/auth/ProtectedRoute.tsx +22 -0
- package/client/landing/src/auth/auth-client.ts +38 -0
- package/client/landing/src/auth/types.ts +18 -0
- package/client/landing/src/components/LandingShell.tsx +34 -0
- package/client/landing/src/lib/specRouteCatalog.json +23 -0
- package/client/landing/src/lib/specScreens.json +17 -0
- package/client/landing/src/main.tsx +17 -0
- package/client/landing/src/pages/LandingHomePage.tsx +215 -0
- package/client/landing/src/pages/LandingLoginPage.tsx +90 -0
- package/client/landing/src/pages/LandingWorkspacePage.tsx +126 -0
- package/client/landing/src/styles/globals.css +17 -0
- package/client/landing/src/theme-vars.ts +16 -0
- package/client/landing/src/theme.ts +21 -0
- package/client/landing/src/vite-env.d.ts +1 -0
- package/client/landing/tailwind.config.js +8 -0
- package/client/landing/tsconfig.json +25 -0
- package/client/landing/vite.config.ts +12 -0
- package/client/mobile/.dockerignore +2 -0
- package/client/mobile/.env.example +1 -0
- package/client/mobile/Dockerfile +16 -0
- package/client/mobile/Dockerfile.dev +18 -0
- package/client/mobile/README.md +19 -0
- package/client/mobile/index.html +12 -0
- package/client/mobile/package.json +42 -0
- package/client/mobile/postcss.config.js +6 -0
- package/client/mobile/scripts/ui-parity-mobile-adapter.mjs +67 -0
- package/client/mobile/src/App.tsx +1 -0
- package/client/mobile/src/api/client.ts +62 -0
- package/client/mobile/src/api/fulfillment.ts +55 -0
- package/client/mobile/src/api/shipping.ts +56 -0
- package/client/mobile/src/app/App.tsx +23 -0
- package/client/mobile/src/auth/AuthProvider.tsx +122 -0
- package/client/mobile/src/auth/ProtectedRoute.tsx +27 -0
- package/client/mobile/src/auth/auth-client.ts +38 -0
- package/client/mobile/src/auth/types.ts +18 -0
- package/client/mobile/src/components/InShell.tsx +74 -0
- package/client/mobile/src/components/ui/button.tsx +35 -0
- package/client/mobile/src/components/ui/card.tsx +15 -0
- package/client/mobile/src/components/ui/input.tsx +21 -0
- package/client/mobile/src/lib/cn.ts +6 -0
- package/client/mobile/src/lib/specRouteCatalog.json +26 -0
- package/client/mobile/src/lib/specScreens.json +22 -0
- package/client/mobile/src/lib/useSpeechRecognitionInput.ts +271 -0
- package/client/mobile/src/main.tsx +17 -0
- package/client/mobile/src/pages/DashboardPage.tsx +172 -0
- package/client/mobile/src/pages/FulfillmentPage.tsx +138 -0
- package/client/mobile/src/pages/LoginPage.tsx +74 -0
- package/client/mobile/src/pages/ShippingPage.tsx +338 -0
- package/client/mobile/src/styles/globals.css +23 -0
- package/client/mobile/src/theme-vars.ts +16 -0
- package/client/mobile/src/theme.ts +21 -0
- package/client/mobile/src/vite-env.d.ts +1 -0
- package/client/mobile/tailwind.config.js +8 -0
- package/client/mobile/tsconfig.json +25 -0
- package/client/mobile/vite.config.ts +12 -0
- package/client/platform/.dockerignore +3 -0
- package/client/platform/.env.example +1 -0
- package/client/platform/Dockerfile +16 -0
- package/client/platform/Dockerfile.dev +18 -0
- package/client/platform/README.md +47 -0
- package/client/platform/index.html +12 -0
- package/client/platform/package.json +42 -0
- package/client/platform/postcss.config.js +6 -0
- package/client/platform/scripts/ui-parity-platform-adapter.mjs +66 -0
- package/client/platform/src/api/client.ts +30 -0
- package/client/platform/src/api/orders.ts +42 -0
- package/client/platform/src/app/App.tsx +21 -0
- package/client/platform/src/auth/AuthProvider.tsx +122 -0
- package/client/platform/src/auth/ProtectedRoute.tsx +22 -0
- package/client/platform/src/auth/auth-client.ts +38 -0
- package/client/platform/src/auth/types.ts +18 -0
- package/client/platform/src/components/AppShell.tsx +59 -0
- package/client/platform/src/components/ui/button.tsx +35 -0
- package/client/platform/src/components/ui/card.tsx +7 -0
- package/client/platform/src/components/ui/input.tsx +21 -0
- package/client/platform/src/lib/cn.ts +6 -0
- package/client/platform/src/lib/specRouteCatalog.json +23 -0
- package/client/platform/src/lib/specScreens.json +17 -0
- package/client/platform/src/main.tsx +17 -0
- package/client/platform/src/pages/DashboardPage.tsx +158 -0
- package/client/platform/src/pages/LoginPage.tsx +72 -0
- package/client/platform/src/pages/OrdersPage.tsx +123 -0
- package/client/platform/src/styles/globals.css +17 -0
- package/client/platform/src/theme-vars.ts +18 -0
- package/client/platform/src/theme.ts +25 -0
- package/client/platform/src/vite-env.d.ts +1 -0
- package/client/platform/tailwind.config.js +8 -0
- package/client/platform/tsconfig.json +25 -0
- package/client/platform/vite.config.ts +12 -0
- package/compose.yml +206 -0
- package/infra/compose/.env.dev.example +28 -0
- package/infra/compose/.env.prod.example +29 -0
- package/infra/compose/README.md +35 -0
- package/infra/compose/dev.yml +125 -0
- package/infra/compose/prod.yml +126 -0
- package/infra/terraform/README.md +34 -0
- package/infra/terraform/aws/data/.terraform.lock.hcl +25 -0
- package/infra/terraform/aws/data/README.md +18 -0
- package/infra/terraform/aws/data/main.tf +147 -0
- package/infra/terraform/aws/data/outputs.tf +14 -0
- package/infra/terraform/aws/data/variables.tf +57 -0
- package/infra/terraform/aws/data/versions.tf +10 -0
- package/infra/terraform/aws/domain/.terraform.lock.hcl +25 -0
- package/infra/terraform/aws/domain/README.md +20 -0
- package/infra/terraform/aws/domain/env/dev.tfvars.example +6 -0
- package/infra/terraform/aws/domain/env/prod.tfvars.example +7 -0
- package/infra/terraform/aws/domain/main.tf +149 -0
- package/infra/terraform/aws/domain/outputs.tf +29 -0
- package/infra/terraform/aws/domain/variables.tf +58 -0
- package/infra/terraform/aws/domain/versions.tf +10 -0
- package/infra/terraform/openstack/README.md +38 -0
- package/infra/terraform/openstack/dev/.terraform.lock.hcl +24 -0
- package/infra/terraform/openstack/dev/README.md +18 -0
- package/infra/terraform/openstack/dev/main.tf +49 -0
- package/infra/terraform/openstack/dev/providers.tf +15 -0
- package/infra/terraform/openstack/dev/terraform.tfvars.example +54 -0
- package/infra/terraform/openstack/dev/variables.tf +210 -0
- package/infra/terraform/openstack/dev/versions.tf +10 -0
- package/infra/terraform/openstack/modules/environment_host/main.tf +143 -0
- package/infra/terraform/openstack/modules/environment_host/outputs.tf +25 -0
- package/infra/terraform/openstack/modules/environment_host/templates/docker-host-user-data.sh.tftpl +40 -0
- package/infra/terraform/openstack/modules/environment_host/variables.tf +145 -0
- package/infra/terraform/openstack/modules/environment_host/versions.tf +7 -0
- package/infra/terraform/openstack/prod/.terraform.lock.hcl +24 -0
- package/infra/terraform/openstack/prod/README.md +18 -0
- package/infra/terraform/openstack/prod/main.tf +49 -0
- package/infra/terraform/openstack/prod/providers.tf +15 -0
- package/infra/terraform/openstack/prod/terraform.tfvars.example +55 -0
- package/infra/terraform/openstack/prod/variables.tf +210 -0
- package/infra/terraform/openstack/prod/versions.tf +10 -0
- package/infra/terraform/openstack/server/.terraform.lock.hcl +45 -0
- package/infra/terraform/openstack/server/README.md +47 -0
- package/infra/terraform/openstack/server/main.tf +161 -0
- package/infra/terraform/openstack/server/outputs.tf +30 -0
- package/infra/terraform/openstack/server/providers.tf +30 -0
- package/infra/terraform/openstack/server/templates/server-user-data.sh.tftpl +50 -0
- package/infra/terraform/openstack/server/variables.tf +233 -0
- package/infra/terraform/openstack/server/zz_aspace.auto.tfvars.example.json +29 -0
- package/lib/scaffold.mjs +373 -0
- package/package.json +33 -12
- package/pnpm-workspace.yaml +2 -0
- package/scripts/dev/audit_sdd_build_ast.py +277 -0
- package/sdd/01_planning/01_feature/INDEX.md +16 -0
- package/sdd/01_planning/01_feature/README.md +76 -0
- package/sdd/01_planning/01_feature/alerts_feature_spec.md +55 -0
- package/sdd/01_planning/01_feature/auth_feature_spec.md +57 -0
- package/sdd/01_planning/01_feature/catalog_feature_spec.md +61 -0
- package/sdd/01_planning/01_feature/fulfillment_feature_spec.md +58 -0
- package/sdd/01_planning/01_feature/health_feature_spec.md +52 -0
- package/sdd/01_planning/01_feature/inventory_feature_spec.md +60 -0
- package/sdd/01_planning/01_feature/order_feature_spec.md +63 -0
- package/sdd/01_planning/01_feature/shipping_feature_spec.md +55 -0
- package/sdd/01_planning/01_feature/support_feature_spec.md +53 -0
- package/sdd/01_planning/01_feature/user_feature_spec.md +54 -0
- package/sdd/01_planning/02_screen/INDEX.md +13 -0
- package/sdd/01_planning/02_screen/README.md +41 -0
- package/sdd/01_planning/02_screen/admin_screen_spec.pdf +0 -0
- package/sdd/01_planning/02_screen/assets/README.md +16 -0
- package/sdd/01_planning/02_screen/assets/example/README.md +13 -0
- package/sdd/01_planning/02_screen/landing_screen_spec.pdf +0 -0
- package/sdd/01_planning/02_screen/mobile_screen_spec.pdf +0 -0
- package/sdd/01_planning/02_screen/platform_screen_spec.pdf +0 -0
- package/sdd/01_planning/03_architecture/INDEX.md +9 -0
- package/sdd/01_planning/03_architecture/README.md +25 -0
- package/sdd/01_planning/03_architecture/architecture_document_structure.md +77 -0
- package/sdd/01_planning/03_architecture/backend/README.md +10 -0
- package/sdd/01_planning/03_architecture/frontend/README.md +12 -0
- package/sdd/01_planning/03_architecture/infra/README.md +10 -0
- package/sdd/01_planning/03_architecture/tech-research/README.md +4 -0
- package/sdd/01_planning/03_architecture/templates_system_architecture.md +84 -0
- package/sdd/01_planning/04_data/INDEX.md +4 -0
- package/sdd/01_planning/04_data/README.md +10 -0
- package/sdd/01_planning/04_data/templates_data_modeling.md +119 -0
- package/sdd/01_planning/05_api/README.md +12 -0
- package/sdd/01_planning/05_api/templates_api_contract.md +90 -0
- package/sdd/01_planning/06_iac/README.md +11 -0
- package/sdd/01_planning/06_iac/templates_runtime_and_cicd_baseline.md +46 -0
- package/sdd/01_planning/07_integration/README.md +11 -0
- package/sdd/01_planning/07_integration/templates_frontend_api_integration.md +46 -0
- package/sdd/01_planning/08_nonfunctional/README.md +7 -0
- package/sdd/01_planning/09_security/README.md +7 -0
- package/sdd/01_planning/10_test/README.md +12 -0
- package/sdd/01_planning/10_test/templates_test_strategy.md +60 -0
- package/sdd/01_planning/INDEX.md +19 -0
- package/sdd/01_planning/README.md +17 -0
- package/sdd/02_plan/01_feature/README.md +34 -0
- package/sdd/02_plan/01_feature/_feature_todo_template.md +29 -0
- package/sdd/02_plan/02_screen/INDEX.md +19 -0
- package/sdd/02_plan/02_screen/README.md +39 -0
- package/sdd/02_plan/02_screen/_screen_todo_template.md +60 -0
- package/sdd/02_plan/03_architecture/README.md +23 -0
- package/sdd/02_plan/03_architecture/architecture_document_governance.md +40 -0
- package/sdd/02_plan/03_architecture/build_ast_runtime_tree_governance.md +53 -0
- package/sdd/02_plan/03_architecture/repository_governance.md +39 -0
- package/sdd/02_plan/03_architecture/runtime_and_structure_governance.md +38 -0
- package/sdd/02_plan/03_architecture/templates-hexagonal-template-architecture.md +9 -0
- package/sdd/02_plan/03_architecture/toolchain_governance.md +98 -0
- package/sdd/02_plan/04_data/README.md +5 -0
- package/sdd/02_plan/05_api/README.md +5 -0
- package/sdd/02_plan/06_iac/README.md +11 -0
- package/sdd/02_plan/06_iac/dev_runtime_delivery.md +36 -0
- package/sdd/02_plan/06_iac/template_runtime_delivery.md +50 -0
- package/sdd/02_plan/07_integration/README.md +5 -0
- package/sdd/02_plan/07_integration/frontend_live_integration.md +31 -0
- package/sdd/02_plan/08_nonfunctional/README.md +5 -0
- package/sdd/02_plan/08_nonfunctional/repository_hygiene.md +26 -0
- package/sdd/02_plan/09_security/README.md +5 -0
- package/sdd/02_plan/10_test/README.md +11 -0
- package/sdd/02_plan/10_test/regression_verification.md +39 -0
- package/sdd/02_plan/10_test/templates/README.md +8 -0
- package/sdd/02_plan/10_test/templates/ui_parity_platform_contract.template.yaml +23 -0
- package/sdd/02_plan/10_test/verification_strategy.md +43 -0
- package/sdd/02_plan/99_generated/from_planning/ui_parity/.gitkeep +1 -0
- package/sdd/02_plan/README.md +40 -0
- package/sdd/03_build/01_feature/README.md +20 -0
- package/sdd/03_build/01_feature/domain/README.md +3 -0
- package/sdd/03_build/01_feature/domain/account_and_access.md +20 -0
- package/sdd/03_build/01_feature/domain/catalog_and_inventory.md +20 -0
- package/sdd/03_build/01_feature/domain/ordering_and_fulfillment.md +21 -0
- package/sdd/03_build/01_feature/domain/support_and_observability.md +21 -0
- package/sdd/03_build/01_feature/domain_surfaces.md +28 -0
- package/sdd/03_build/01_feature/service/README.md +3 -0
- package/sdd/03_build/01_feature/service/admin_surface.md +15 -0
- package/sdd/03_build/01_feature/service/landing_surface.md +13 -0
- package/sdd/03_build/01_feature/service/mobile_surface.md +14 -0
- package/sdd/03_build/01_feature/service/platform_surface.md +14 -0
- package/sdd/03_build/02_screen/README.md +25 -0
- package/sdd/03_build/02_screen/_screen_build_template.md +26 -0
- package/sdd/03_build/02_screen/admin/README.md +5 -0
- package/sdd/03_build/02_screen/landing/README.md +5 -0
- package/sdd/03_build/02_screen/mobile/README.md +5 -0
- package/sdd/03_build/02_screen/platform/README.md +5 -0
- package/sdd/03_build/03_architecture/README.md +10 -0
- package/sdd/03_build/03_architecture/architecture_document_governance.md +30 -0
- package/sdd/03_build/03_architecture/build_ast_runtime_tree_governance.md +24 -0
- package/sdd/03_build/03_architecture/repository_governance.md +18 -0
- package/sdd/03_build/03_architecture/toolchain_governance.md +36 -0
- package/sdd/03_build/06_iac/README.md +3 -0
- package/sdd/03_build/06_iac/dev_runtime_delivery.md +10 -0
- package/sdd/03_build/06_iac/template_runtime_delivery.md +49 -0
- package/sdd/03_build/07_integration/README.md +3 -0
- package/sdd/03_build/07_integration/frontend_live_integration.md +11 -0
- package/sdd/03_build/08_nonfunctional/README.md +3 -0
- package/sdd/03_build/08_nonfunctional/repository_hygiene.md +10 -0
- package/sdd/03_build/10_test/README.md +9 -0
- package/sdd/03_build/10_test/regression_verification.md +16 -0
- package/sdd/03_build/10_test/verification_harness.md +11 -0
- package/sdd/03_build/README.md +35 -0
- package/sdd/04_verify/01_feature/README.md +5 -0
- package/sdd/04_verify/01_feature/domain_verification.md +14 -0
- package/sdd/04_verify/01_feature/service_verification.md +22 -0
- package/sdd/04_verify/02_screen/README.md +6 -0
- package/sdd/04_verify/02_screen/_screen_verify_template.md +20 -0
- package/sdd/04_verify/02_screen/admin/README.md +4 -0
- package/sdd/04_verify/02_screen/landing/README.md +4 -0
- package/sdd/04_verify/02_screen/mobile/README.md +4 -0
- package/sdd/04_verify/02_screen/platform/README.md +4 -0
- package/sdd/04_verify/03_architecture/README.md +10 -0
- package/sdd/04_verify/03_architecture/architecture_document_governance.md +15 -0
- package/sdd/04_verify/03_architecture/build_ast_runtime_tree_governance.md +28 -0
- package/sdd/04_verify/03_architecture/repository_governance.md +16 -0
- package/sdd/04_verify/03_architecture/toolchain_governance.md +58 -0
- package/sdd/04_verify/06_iac/README.md +3 -0
- package/sdd/04_verify/06_iac/dev_runtime_delivery.md +10 -0
- package/sdd/04_verify/06_iac/template_runtime_delivery.md +42 -0
- package/sdd/04_verify/07_integration/README.md +3 -0
- package/sdd/04_verify/07_integration/frontend_live_integration.md +16 -0
- package/sdd/04_verify/08_nonfunctional/README.md +3 -0
- package/sdd/04_verify/08_nonfunctional/repository_hygiene.md +14 -0
- package/sdd/04_verify/10_test/README.md +9 -0
- package/sdd/04_verify/10_test/regression_verification.md +16 -0
- package/sdd/04_verify/10_test/ui_parity/README.md +4 -0
- package/sdd/04_verify/10_test/ui_parity/loop_runs/.gitkeep +0 -0
- package/sdd/04_verify/10_test/ui_parity/reference/.gitkeep +0 -0
- package/sdd/04_verify/10_test/ui_parity/staged_runs/.gitkeep +0 -0
- package/sdd/04_verify/10_test/verification_harness.md +17 -0
- package/sdd/04_verify/README.md +22 -0
- package/sdd/05_operate/01_runbooks/.gitkeep +1 -0
- package/sdd/05_operate/01_runbooks/README.md +4 -0
- package/sdd/05_operate/02_delivery_status/README.md +4 -0
- package/sdd/05_operate/02_delivery_status/service_status.md +16 -0
- package/sdd/05_operate/README.md +12 -0
- package/sdd/99_toolchain/01_automation/.gitkeep +1 -0
- package/sdd/99_toolchain/01_automation/README.md +76 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/analyze_proof_results.py +132 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/analyze_route_gap.py +85 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/assets/repo-contract.template.json +75 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/bootstrap_frontend_parity.sh +84 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/init_frontend_parity.sh +33 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/init_repo_contract.sh +51 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/repo-contract.json +76 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/resolve_frontend_target.py +52 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/resolve_repo_contract.py +56 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/run_frontend_target.sh +100 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/run_repo_phase.sh +140 -0
- package/sdd/99_toolchain/01_automation/agentic-dev/validate_json_schema.py +39 -0
- package/sdd/99_toolchain/01_automation/agentic-parity-harness-design.md +291 -0
- package/sdd/99_toolchain/01_automation/assets/admin_screen_capture/dashboard.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/admin_screen_capture/login.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/admin_screen_capture/queue.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/admin_screen_capture/support.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/landing_screen_capture/home.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/landing_screen_capture/login.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/landing_screen_capture/workspace.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/mobile_screen_capture/dashboard.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/mobile_screen_capture/fulfillment.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/mobile_screen_capture/login.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/platform_screen_capture/dashboard.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/platform_screen_capture/login.png +0 -0
- package/sdd/99_toolchain/01_automation/assets/platform_screen_capture/orders.png +0 -0
- package/sdd/99_toolchain/01_automation/build_asset_recipes.py +10 -0
- package/sdd/99_toolchain/01_automation/build_screen_spec_pdf.py +427 -0
- package/sdd/99_toolchain/01_automation/capture_screen_assets.mjs +148 -0
- package/sdd/99_toolchain/01_automation/harness-layout.md +34 -0
- package/sdd/99_toolchain/01_automation/parity-execution-tooling-design.md +319 -0
- package/sdd/99_toolchain/01_automation/playwright_exactness_manifest.py +21 -0
- package/sdd/99_toolchain/01_automation/run_playwright_exactness.py +87 -0
- package/sdd/99_toolchain/01_automation/screen_spec_manifest.py +321 -0
- package/sdd/99_toolchain/01_automation/spec_asset_builder.py +274 -0
- package/sdd/99_toolchain/01_automation/ui-contract-projection.md +79 -0
- package/sdd/99_toolchain/01_automation/ui-parity/README.md +60 -0
- package/sdd/99_toolchain/01_automation/ui-parity/cli/extract-reference-pages.mjs +2 -0
- package/sdd/99_toolchain/01_automation/ui-parity/cli/materialize-reference-assets.mjs +58 -0
- package/sdd/99_toolchain/01_automation/ui-parity/cli/normalize-reference-assets.mjs +2 -0
- package/sdd/99_toolchain/01_automation/ui-parity/cli/route-gap-report.mjs +187 -0
- package/sdd/99_toolchain/01_automation/ui-parity/cli/run-proof.mjs +50 -0
- package/sdd/99_toolchain/01_automation/ui-parity/cli/scaffold-contract.mjs +62 -0
- package/sdd/99_toolchain/01_automation/ui-parity/cli/upload-parity1.mjs +2 -0
- package/sdd/99_toolchain/01_automation/ui-parity/contracts/collector-metadata.schema.json +33 -0
- package/sdd/99_toolchain/01_automation/ui-parity/contracts/proof-result.schema.json +76 -0
- package/sdd/99_toolchain/01_automation/ui-parity/contracts/route-gap-report.schema.json +95 -0
- package/sdd/99_toolchain/01_automation/ui-parity/core/capture-runner.mjs +55 -0
- package/sdd/99_toolchain/01_automation/ui-parity/core/load-adapter.mjs +25 -0
- package/sdd/99_toolchain/01_automation/ui-parity/core/load-contract.mjs +81 -0
- package/sdd/99_toolchain/01_automation/ui-parity/core/paths.mjs +23 -0
- package/sdd/99_toolchain/01_automation/ui-parity/core/proof-runner.mjs +255 -0
- package/sdd/99_toolchain/01_automation/ui-parity/interfaces/ui-parity-artifact-layout.md +23 -0
- package/sdd/99_toolchain/01_automation/ui-parity/interfaces/ui-parity-proof-interface.md +60 -0
- package/sdd/99_toolchain/01_automation/ui-parity/interfaces/ui-parity-route-gap-interface.md +82 -0
- package/sdd/99_toolchain/01_automation/ui-parity/runtime/playwright-runtime.mjs +16 -0
- package/sdd/99_toolchain/01_automation/ui-parity/runtime/static-runtime.mjs +6 -0
- package/sdd/99_toolchain/02_policies/.gitkeep +1 -0
- package/sdd/99_toolchain/02_policies/build-ast-governance-policy.md +22 -0
- package/sdd/99_toolchain/02_policies/compose-runtime-baseline-policy.md +24 -0
- package/sdd/99_toolchain/02_policies/convention-storage-policy.md +26 -0
- package/sdd/99_toolchain/02_policies/main-push-before-dev-deploy-policy.md +27 -0
- package/sdd/99_toolchain/02_policies/otro-orchestration-policy.md +30 -0
- package/sdd/99_toolchain/02_policies/regression-verification-policy.md +22 -0
- package/sdd/99_toolchain/03_templates/.gitkeep +1 -0
- package/sdd/99_toolchain/03_templates/asset_recipe_manifest.example.py +38 -0
- package/sdd/99_toolchain/03_templates/generated_assets/README.md +11 -0
- package/sdd/99_toolchain/03_templates/generated_assets/example-brand-lockup.svg +3 -0
- package/sdd/99_toolchain/03_templates/generated_assets/example-brand-mark.svg +3 -0
- package/sdd/99_toolchain/03_templates/generated_assets/example-brand-wordmark.svg +3 -0
- package/sdd/99_toolchain/03_templates/playwright_exactness_manifest.example.py +21 -0
- package/sdd/99_toolchain/README.md +23 -0
- package/sdd/README.md +21 -0
- package/server/.dockerignore +4 -0
- package/server/.env.example +19 -0
- package/server/Dockerfile +22 -0
- package/server/Dockerfile.dev +19 -0
- package/server/README.md +33 -0
- package/server/__init__.py +0 -0
- package/server/api/__init__.py +1 -0
- package/server/api/http/__init__.py +4 -0
- package/server/api/http/app.py +53 -0
- package/server/api/http/router.py +24 -0
- package/server/config.py +52 -0
- package/server/contexts/__init__.py +12 -0
- package/server/contexts/alerts/__init__.py +1 -0
- package/server/contexts/alerts/application/__init__.py +13 -0
- package/server/contexts/alerts/application/services.py +41 -0
- package/server/contexts/alerts/contracts/__init__.py +3 -0
- package/server/contexts/alerts/contracts/http/__init__.py +3 -0
- package/server/contexts/alerts/contracts/http/router.py +37 -0
- package/server/contexts/alerts/domain/__init__.py +15 -0
- package/server/contexts/alerts/domain/models.py +29 -0
- package/server/contexts/alerts/infrastructure/__init__.py +11 -0
- package/server/contexts/alerts/infrastructure/repository.py +41 -0
- package/server/contexts/auth/__init__.py +1 -0
- package/server/contexts/auth/application/__init__.py +3 -0
- package/server/contexts/auth/application/ports.py +10 -0
- package/server/contexts/auth/application/services.py +64 -0
- package/server/contexts/auth/contracts/__init__.py +4 -0
- package/server/contexts/auth/contracts/http/__init__.py +4 -0
- package/server/contexts/auth/contracts/http/dependencies.py +37 -0
- package/server/contexts/auth/contracts/http/router.py +19 -0
- package/server/contexts/auth/domain/__init__.py +3 -0
- package/server/contexts/auth/domain/models.py +24 -0
- package/server/contexts/auth/infrastructure/__init__.py +4 -0
- package/server/contexts/auth/infrastructure/adapters/memory.py +19 -0
- package/server/contexts/auth/infrastructure/adapters/mongodb.py +24 -0
- package/server/contexts/auth/infrastructure/adapters/sqlalchemy.py +74 -0
- package/server/contexts/auth/infrastructure/repository.py +28 -0
- package/server/contexts/catalog/__init__.py +1 -0
- package/server/contexts/catalog/application/__init__.py +28 -0
- package/server/contexts/catalog/application/ports.py +15 -0
- package/server/contexts/catalog/application/services.py +154 -0
- package/server/contexts/catalog/contracts/__init__.py +3 -0
- package/server/contexts/catalog/contracts/http/__init__.py +3 -0
- package/server/contexts/catalog/contracts/http/router.py +60 -0
- package/server/contexts/catalog/domain/__init__.py +45 -0
- package/server/contexts/catalog/domain/models.py +113 -0
- package/server/contexts/catalog/infrastructure/__init__.py +4 -0
- package/server/contexts/catalog/infrastructure/adapters/memory.py +62 -0
- package/server/contexts/catalog/infrastructure/repository.py +8 -0
- package/server/contexts/fulfillment/__init__.py +1 -0
- package/server/contexts/fulfillment/application/__init__.py +13 -0
- package/server/contexts/fulfillment/application/ports.py +20 -0
- package/server/contexts/fulfillment/application/services.py +85 -0
- package/server/contexts/fulfillment/contracts/__init__.py +3 -0
- package/server/contexts/fulfillment/contracts/http/__init__.py +3 -0
- package/server/contexts/fulfillment/contracts/http/router.py +40 -0
- package/server/contexts/fulfillment/domain/__init__.py +25 -0
- package/server/contexts/fulfillment/domain/models.py +73 -0
- package/server/contexts/fulfillment/infrastructure/__init__.py +13 -0
- package/server/contexts/fulfillment/infrastructure/adapters/memory.py +43 -0
- package/server/contexts/fulfillment/infrastructure/repository.py +97 -0
- package/server/contexts/health/__init__.py +1 -0
- package/server/contexts/health/application/__init__.py +3 -0
- package/server/contexts/health/application/services.py +2 -0
- package/server/contexts/health/contracts/__init__.py +3 -0
- package/server/contexts/health/contracts/http/__init__.py +3 -0
- package/server/contexts/health/contracts/http/router.py +10 -0
- package/server/contexts/inventory/__init__.py +1 -0
- package/server/contexts/inventory/application/__init__.py +28 -0
- package/server/contexts/inventory/application/ports.py +11 -0
- package/server/contexts/inventory/application/services.py +214 -0
- package/server/contexts/inventory/contracts/__init__.py +3 -0
- package/server/contexts/inventory/contracts/http/__init__.py +3 -0
- package/server/contexts/inventory/contracts/http/router.py +82 -0
- package/server/contexts/inventory/domain/__init__.py +33 -0
- package/server/contexts/inventory/domain/models.py +93 -0
- package/server/contexts/inventory/infrastructure/__init__.py +4 -0
- package/server/contexts/inventory/infrastructure/adapters/memory.py +24 -0
- package/server/contexts/inventory/infrastructure/repository.py +8 -0
- package/server/contexts/orders/__init__.py +1 -0
- package/server/contexts/orders/application/__init__.py +19 -0
- package/server/contexts/orders/application/services.py +127 -0
- package/server/contexts/orders/contracts/__init__.py +3 -0
- package/server/contexts/orders/contracts/http/__init__.py +3 -0
- package/server/contexts/orders/contracts/http/router.py +82 -0
- package/server/contexts/orders/domain/__init__.py +29 -0
- package/server/contexts/orders/domain/models.py +95 -0
- package/server/contexts/orders/infrastructure/__init__.py +7 -0
- package/server/contexts/orders/infrastructure/repository.py +104 -0
- package/server/contexts/shipping/__init__.py +1 -0
- package/server/contexts/shipping/application/__init__.py +13 -0
- package/server/contexts/shipping/application/services.py +92 -0
- package/server/contexts/shipping/contracts/__init__.py +3 -0
- package/server/contexts/shipping/contracts/http/__init__.py +3 -0
- package/server/contexts/shipping/contracts/http/router.py +40 -0
- package/server/contexts/shipping/domain/__init__.py +19 -0
- package/server/contexts/shipping/domain/models.py +48 -0
- package/server/contexts/shipping/infrastructure/__init__.py +9 -0
- package/server/contexts/shipping/infrastructure/repository.py +50 -0
- package/server/contexts/support/__init__.py +1 -0
- package/server/contexts/support/application/__init__.py +13 -0
- package/server/contexts/support/application/services.py +29 -0
- package/server/contexts/support/contracts/__init__.py +3 -0
- package/server/contexts/support/contracts/http/__init__.py +3 -0
- package/server/contexts/support/contracts/http/router.py +40 -0
- package/server/contexts/support/domain/__init__.py +13 -0
- package/server/contexts/support/domain/models.py +27 -0
- package/server/contexts/support/infrastructure/__init__.py +11 -0
- package/server/contexts/support/infrastructure/repository.py +70 -0
- package/server/contexts/user/__init__.py +1 -0
- package/server/contexts/user/application/__init__.py +3 -0
- package/server/contexts/user/application/ports.py +11 -0
- package/server/contexts/user/application/services.py +44 -0
- package/server/contexts/user/contracts/__init__.py +3 -0
- package/server/contexts/user/contracts/http/__init__.py +3 -0
- package/server/contexts/user/contracts/http/router.py +26 -0
- package/server/contexts/user/domain/__init__.py +3 -0
- package/server/contexts/user/domain/models.py +22 -0
- package/server/contexts/user/infrastructure/__init__.py +3 -0
- package/server/contexts/user/infrastructure/adapters/memory.py +27 -0
- package/server/contexts/user/infrastructure/adapters/mongodb.py +41 -0
- package/server/contexts/user/infrastructure/adapters/sqlalchemy.py +94 -0
- package/server/contexts/user/infrastructure/factory.py +28 -0
- package/server/data/README.md +24 -0
- package/server/data/bootstrap/alerts.json +38 -0
- package/server/data/bootstrap/auth_accounts.json +18 -0
- package/server/data/bootstrap/catalog_products.json +179 -0
- package/server/data/bootstrap/fulfillment_events.json +5 -0
- package/server/data/bootstrap/fulfillment_notes.json +5 -0
- package/server/data/bootstrap/fulfillment_tasks.json +50 -0
- package/server/data/bootstrap/inventory_levels.json +80 -0
- package/server/data/bootstrap/orders.json +62 -0
- package/server/data/bootstrap/shipping_shipments.json +50 -0
- package/server/data/bootstrap/support_faqs.json +26 -0
- package/server/data/bootstrap/users.json +20 -0
- package/server/data/bootstrap_loader.py +15 -0
- package/server/docker-entrypoint.sh +56 -0
- package/server/main.py +3 -0
- package/server/pyproject.toml +36 -0
- package/server/shared/__init__.py +1 -0
- package/server/shared/application/__init__.py +3 -0
- package/server/shared/application/health.py +2 -0
- package/server/shared/infrastructure/__init__.py +10 -0
- package/server/shared/infrastructure/runtime.py +6 -0
- package/server/shared/infrastructure/security.py +33 -0
- package/server/tests/e2e/test_domain_feature_flows.py +483 -0
- package/server/tests/test_health.py +49 -0
- package/server/uv.lock +1169 -0
- package/bin/agentic-dev.js +0 -9
- package/src/cli.js +0 -37
- package/src/init-command.js +0 -230
- package/src/lib/command.js +0 -14
- package/src/lib/fs.js +0 -92
- package/src/lib/git.js +0 -57
- package/src/lib/github.js +0 -77
- package/src/lib/prompt.js +0 -52
- package/src/lib/system.js +0 -15
- package/src/lib/template.js +0 -143
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { useState } from "react";
|
|
2
|
+
import { Navigate, useLocation } from "react-router-dom";
|
|
3
|
+
|
|
4
|
+
import { useAuth } from "@/auth/AuthProvider";
|
|
5
|
+
import { Button } from "@/components/ui/button";
|
|
6
|
+
import { Card } from "@/components/ui/card";
|
|
7
|
+
import { Input } from "@/components/ui/input";
|
|
8
|
+
import { appTheme } from "@/theme";
|
|
9
|
+
import { appThemeVars } from "@/theme-vars";
|
|
10
|
+
|
|
11
|
+
export function LoginPage() {
|
|
12
|
+
const { authenticating, login, user } = useAuth();
|
|
13
|
+
const location = useLocation();
|
|
14
|
+
const [email, setEmail] = useState("admin@example.com");
|
|
15
|
+
const [password, setPassword] = useState("");
|
|
16
|
+
const [error, setError] = useState<string | null>(null);
|
|
17
|
+
|
|
18
|
+
if (user) {
|
|
19
|
+
const destination = (location.state as { from?: { pathname?: string } } | null)?.from?.pathname ?? "/";
|
|
20
|
+
return <Navigate to={destination} replace />;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
async function handleSubmit(event: React.FormEvent<HTMLFormElement>) {
|
|
24
|
+
event.preventDefault();
|
|
25
|
+
setError(null);
|
|
26
|
+
|
|
27
|
+
try {
|
|
28
|
+
await login({ email, password });
|
|
29
|
+
} catch (submitError) {
|
|
30
|
+
setError(submitError instanceof Error ? submitError.message : "로그인에 실패했습니다.");
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
return (
|
|
35
|
+
<div className="min-h-screen bg-[var(--app-shell-bg)] px-6 py-12 text-[#22314d]" style={appThemeVars(appTheme)}>
|
|
36
|
+
<div className="mx-auto grid max-w-6xl gap-10 lg:grid-cols-[1.1fr_420px] lg:items-center">
|
|
37
|
+
<div>
|
|
38
|
+
<p className="inline-flex rounded-full bg-white px-4 py-2 text-sm font-semibold text-[#223a82] shadow-sm">Customer workspace</p>
|
|
39
|
+
<h1 className="mt-6 text-5xl font-black tracking-[-0.04em] text-[#16253f]">실제 API에 연결된 로그인 흐름</h1>
|
|
40
|
+
<p className="mt-5 max-w-xl text-lg leading-8 text-[#5f6e86]">
|
|
41
|
+
`VITE_API_BASE_URL/auth/login`으로 인증하고, 저장된 토큰으로 `auth/me`를 다시 호출해 앱 셸을 엽니다.
|
|
42
|
+
</p>
|
|
43
|
+
</div>
|
|
44
|
+
|
|
45
|
+
<Card className="border-[var(--app-border)] bg-white p-7 shadow-[0_24px_60px_rgba(31,58,138,0.1)]">
|
|
46
|
+
<form className="space-y-5" onSubmit={handleSubmit}>
|
|
47
|
+
<div>
|
|
48
|
+
<p className="text-2xl font-bold text-[#16253f]">Sign in</p>
|
|
49
|
+
<p className="mt-2 text-sm text-[#6b7890]">예시 계정 값이 기본으로 채워져 있습니다.</p>
|
|
50
|
+
</div>
|
|
51
|
+
|
|
52
|
+
<label className="block space-y-2">
|
|
53
|
+
<span className="text-sm font-semibold text-[#314157]">Email</span>
|
|
54
|
+
<Input type="email" value={email} onChange={(event) => setEmail(event.target.value)} required />
|
|
55
|
+
</label>
|
|
56
|
+
|
|
57
|
+
<label className="block space-y-2">
|
|
58
|
+
<span className="text-sm font-semibold text-[#314157]">Password</span>
|
|
59
|
+
<Input type="password" value={password} onChange={(event) => setPassword(event.target.value)} required />
|
|
60
|
+
</label>
|
|
61
|
+
|
|
62
|
+
{error ? <p className="text-sm font-medium text-[#c53030]">{error}</p> : null}
|
|
63
|
+
|
|
64
|
+
<Button className="w-full" size="lg" type="submit" disabled={authenticating}>
|
|
65
|
+
{authenticating ? "Signing in..." : "Continue to app"}
|
|
66
|
+
</Button>
|
|
67
|
+
</form>
|
|
68
|
+
</Card>
|
|
69
|
+
</div>
|
|
70
|
+
</div>
|
|
71
|
+
);
|
|
72
|
+
}
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
import { useEffect, useState } from "react";
|
|
2
|
+
import { Search } from "lucide-react";
|
|
3
|
+
|
|
4
|
+
import { useAuth } from "@/auth/AuthProvider";
|
|
5
|
+
import { fetchOrders, type OrderSummary } from "@/api/orders";
|
|
6
|
+
import { Button } from "@/components/ui/button";
|
|
7
|
+
import { Card } from "@/components/ui/card";
|
|
8
|
+
import { Input } from "@/components/ui/input";
|
|
9
|
+
|
|
10
|
+
export function OrdersPage() {
|
|
11
|
+
const { token } = useAuth();
|
|
12
|
+
const [orders, setOrders] = useState<OrderSummary[]>([]);
|
|
13
|
+
const [query, setQuery] = useState("");
|
|
14
|
+
const [loading, setLoading] = useState(true);
|
|
15
|
+
const [error, setError] = useState<string | null>(null);
|
|
16
|
+
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
if (!token?.access_token) {
|
|
19
|
+
return;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
let cancelled = false;
|
|
23
|
+
|
|
24
|
+
setLoading(true);
|
|
25
|
+
setError(null);
|
|
26
|
+
|
|
27
|
+
fetchOrders(token.access_token)
|
|
28
|
+
.then((response) => {
|
|
29
|
+
if (!cancelled) {
|
|
30
|
+
setOrders(response);
|
|
31
|
+
}
|
|
32
|
+
})
|
|
33
|
+
.catch((nextError: Error) => {
|
|
34
|
+
if (!cancelled) {
|
|
35
|
+
setError(nextError.message);
|
|
36
|
+
setOrders([]);
|
|
37
|
+
}
|
|
38
|
+
})
|
|
39
|
+
.finally(() => {
|
|
40
|
+
if (!cancelled) {
|
|
41
|
+
setLoading(false);
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
return () => {
|
|
46
|
+
cancelled = true;
|
|
47
|
+
};
|
|
48
|
+
}, [token?.access_token]);
|
|
49
|
+
|
|
50
|
+
const normalizedQuery = query.trim().toLowerCase();
|
|
51
|
+
const filteredOrders = orders.filter((order) =>
|
|
52
|
+
[order.id, order.product_name, order.customer_name, order.status].some((field) =>
|
|
53
|
+
field.toLowerCase().includes(normalizedQuery),
|
|
54
|
+
),
|
|
55
|
+
);
|
|
56
|
+
|
|
57
|
+
return (
|
|
58
|
+
<div className="space-y-6">
|
|
59
|
+
<Card className="p-[var(--app-card-padding)]">
|
|
60
|
+
<div className="flex flex-wrap items-center gap-3">
|
|
61
|
+
<div className="relative min-w-[280px] flex-1">
|
|
62
|
+
<Search className="pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-[#8d97a8]" />
|
|
63
|
+
<Input className="pl-9" placeholder="Search orders" value={query} onChange={(event) => setQuery(event.target.value)} />
|
|
64
|
+
</div>
|
|
65
|
+
<Button variant="outline" onClick={() => setQuery("")}>
|
|
66
|
+
Reset
|
|
67
|
+
</Button>
|
|
68
|
+
<Button>New order</Button>
|
|
69
|
+
</div>
|
|
70
|
+
<p className="mt-4 text-sm text-[var(--app-muted)]">
|
|
71
|
+
{loading ? "Loading order list..." : `Showing ${filteredOrders.length} of ${orders.length} orders`}
|
|
72
|
+
</p>
|
|
73
|
+
</Card>
|
|
74
|
+
|
|
75
|
+
<Card className="overflow-hidden">
|
|
76
|
+
<table className="w-full border-collapse text-sm">
|
|
77
|
+
<thead className="bg-[#f8fafe] text-left text-[#516174]">
|
|
78
|
+
<tr>
|
|
79
|
+
{["Order", "Product", "Customer", "Status"].map((cell) => (
|
|
80
|
+
<th key={cell} className="border-y border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)] font-semibold">
|
|
81
|
+
{cell}
|
|
82
|
+
</th>
|
|
83
|
+
))}
|
|
84
|
+
</tr>
|
|
85
|
+
</thead>
|
|
86
|
+
<tbody>
|
|
87
|
+
{loading ? (
|
|
88
|
+
<tr>
|
|
89
|
+
<td className="border-b border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)] text-[var(--app-muted)]" colSpan={4}>
|
|
90
|
+
Loading orders...
|
|
91
|
+
</td>
|
|
92
|
+
</tr>
|
|
93
|
+
) : null}
|
|
94
|
+
{error ? (
|
|
95
|
+
<tr>
|
|
96
|
+
<td className="border-b border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)] text-[var(--app-danger)]" colSpan={4}>
|
|
97
|
+
{error}
|
|
98
|
+
</td>
|
|
99
|
+
</tr>
|
|
100
|
+
) : null}
|
|
101
|
+
{!loading && !error && !filteredOrders.length ? (
|
|
102
|
+
<tr>
|
|
103
|
+
<td className="border-b border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)] text-[var(--app-muted)]" colSpan={4}>
|
|
104
|
+
No orders matched the current search.
|
|
105
|
+
</td>
|
|
106
|
+
</tr>
|
|
107
|
+
) : null}
|
|
108
|
+
{filteredOrders.map((order) => (
|
|
109
|
+
<tr key={order.id}>
|
|
110
|
+
<td className="border-b border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)] text-[var(--app-accent)]">{order.id}</td>
|
|
111
|
+
<td className="border-b border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)]">{order.product_name}</td>
|
|
112
|
+
<td className="border-b border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)]">{order.customer_name}</td>
|
|
113
|
+
<td className="border-b border-[var(--app-border)] px-[var(--app-table-cell-px)] py-[var(--app-table-cell-py)]">
|
|
114
|
+
<span className={order.status === "At risk" ? "text-[var(--app-danger)]" : "text-[#314157]"}>{order.status}</span>
|
|
115
|
+
</td>
|
|
116
|
+
</tr>
|
|
117
|
+
))}
|
|
118
|
+
</tbody>
|
|
119
|
+
</table>
|
|
120
|
+
</Card>
|
|
121
|
+
</div>
|
|
122
|
+
);
|
|
123
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
@tailwind base;
|
|
2
|
+
@tailwind components;
|
|
3
|
+
@tailwind utilities;
|
|
4
|
+
|
|
5
|
+
:root {
|
|
6
|
+
color-scheme: light;
|
|
7
|
+
font-family: "SUIT", "Pretendard", "Noto Sans KR", sans-serif;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
body {
|
|
11
|
+
margin: 0;
|
|
12
|
+
background: var(--app-shell-bg, #f5f7fb);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
* {
|
|
16
|
+
box-sizing: border-box;
|
|
17
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { CSSProperties } from "react";
|
|
2
|
+
|
|
3
|
+
import type { AppTheme } from "./theme";
|
|
4
|
+
|
|
5
|
+
export function appThemeVars(theme: AppTheme): CSSProperties {
|
|
6
|
+
return {
|
|
7
|
+
"--app-shell-bg": theme.shellBg,
|
|
8
|
+
"--app-card-radius": theme.cardRadius,
|
|
9
|
+
"--app-card-padding": theme.cardPadding,
|
|
10
|
+
"--app-border": theme.border,
|
|
11
|
+
"--app-accent": theme.accent,
|
|
12
|
+
"--app-danger": theme.danger,
|
|
13
|
+
"--app-muted": theme.muted,
|
|
14
|
+
"--app-table-cell-py": theme.tableCellPy,
|
|
15
|
+
"--app-table-cell-px": theme.tableCellPx,
|
|
16
|
+
"--app-panel-width": theme.panelWidth,
|
|
17
|
+
} as CSSProperties;
|
|
18
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export type AppTheme = {
|
|
2
|
+
shellBg: string;
|
|
3
|
+
cardRadius: string;
|
|
4
|
+
cardPadding: string;
|
|
5
|
+
border: string;
|
|
6
|
+
accent: string;
|
|
7
|
+
danger: string;
|
|
8
|
+
muted: string;
|
|
9
|
+
tableCellPy: string;
|
|
10
|
+
tableCellPx: string;
|
|
11
|
+
panelWidth: string;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export const appTheme: AppTheme = {
|
|
15
|
+
shellBg: "#f5f7fb",
|
|
16
|
+
cardRadius: "18px",
|
|
17
|
+
cardPadding: "20px",
|
|
18
|
+
border: "#e8edf5",
|
|
19
|
+
accent: "#496fe8",
|
|
20
|
+
danger: "#d95d4a",
|
|
21
|
+
muted: "#708097",
|
|
22
|
+
tableCellPy: "14px",
|
|
23
|
+
tableCellPx: "16px",
|
|
24
|
+
panelWidth: "340px",
|
|
25
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
/// <reference types="vite/client" />
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "ES2020",
|
|
4
|
+
"useDefineForClassFields": true,
|
|
5
|
+
"lib": ["ES2020", "DOM", "DOM.Iterable"],
|
|
6
|
+
"allowJs": false,
|
|
7
|
+
"skipLibCheck": true,
|
|
8
|
+
"esModuleInterop": true,
|
|
9
|
+
"allowSyntheticDefaultImports": true,
|
|
10
|
+
"strict": true,
|
|
11
|
+
"forceConsistentCasingInFileNames": true,
|
|
12
|
+
"module": "ESNext",
|
|
13
|
+
"moduleResolution": "Node",
|
|
14
|
+
"resolveJsonModule": true,
|
|
15
|
+
"isolatedModules": true,
|
|
16
|
+
"noEmit": true,
|
|
17
|
+
"jsx": "react-jsx",
|
|
18
|
+
"baseUrl": ".",
|
|
19
|
+
"paths": {
|
|
20
|
+
"@/*": ["src/*"]
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"include": ["src"],
|
|
24
|
+
"references": []
|
|
25
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { defineConfig } from "vite";
|
|
2
|
+
import react from "@vitejs/plugin-react";
|
|
3
|
+
import { fileURLToPath, URL } from "node:url";
|
|
4
|
+
|
|
5
|
+
export default defineConfig({
|
|
6
|
+
plugins: [react()],
|
|
7
|
+
resolve: {
|
|
8
|
+
alias: {
|
|
9
|
+
"@": fileURLToPath(new URL("./src", import.meta.url)),
|
|
10
|
+
},
|
|
11
|
+
},
|
|
12
|
+
});
|
package/compose.yml
ADDED
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
name: templates
|
|
2
|
+
|
|
3
|
+
services:
|
|
4
|
+
postgres:
|
|
5
|
+
image: postgres:16-alpine
|
|
6
|
+
environment:
|
|
7
|
+
POSTGRES_DB: ${POSTGRES_DB:-template}
|
|
8
|
+
POSTGRES_USER: ${POSTGRES_USER:-template}
|
|
9
|
+
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-template}
|
|
10
|
+
ports:
|
|
11
|
+
- "${POSTGRES_PORT:-5432}:5432"
|
|
12
|
+
volumes:
|
|
13
|
+
- postgres_data:/var/lib/postgresql/data
|
|
14
|
+
healthcheck:
|
|
15
|
+
test:
|
|
16
|
+
[
|
|
17
|
+
"CMD-SHELL",
|
|
18
|
+
"pg_isready -U ${POSTGRES_USER:-template} -d ${POSTGRES_DB:-template}",
|
|
19
|
+
]
|
|
20
|
+
interval: 10s
|
|
21
|
+
timeout: 5s
|
|
22
|
+
retries: 5
|
|
23
|
+
networks:
|
|
24
|
+
- template-dev
|
|
25
|
+
|
|
26
|
+
mysql:
|
|
27
|
+
image: mysql:8.4
|
|
28
|
+
profiles: ["mysql"]
|
|
29
|
+
environment:
|
|
30
|
+
MYSQL_DATABASE: ${MYSQL_DATABASE:-template}
|
|
31
|
+
MYSQL_USER: ${MYSQL_USER:-template}
|
|
32
|
+
MYSQL_PASSWORD: ${MYSQL_PASSWORD:-template}
|
|
33
|
+
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD:-template-root}
|
|
34
|
+
ports:
|
|
35
|
+
- "${MYSQL_PORT:-3306}:3306"
|
|
36
|
+
volumes:
|
|
37
|
+
- mysql_data:/var/lib/mysql
|
|
38
|
+
healthcheck:
|
|
39
|
+
test:
|
|
40
|
+
[
|
|
41
|
+
"CMD-SHELL",
|
|
42
|
+
"mysqladmin ping -h 127.0.0.1 -u${MYSQL_USER:-template} -p${MYSQL_PASSWORD:-template}",
|
|
43
|
+
]
|
|
44
|
+
interval: 10s
|
|
45
|
+
timeout: 5s
|
|
46
|
+
retries: 10
|
|
47
|
+
start_period: 20s
|
|
48
|
+
networks:
|
|
49
|
+
- template-dev
|
|
50
|
+
|
|
51
|
+
mariadb:
|
|
52
|
+
image: mariadb:11.7
|
|
53
|
+
profiles: ["mariadb"]
|
|
54
|
+
environment:
|
|
55
|
+
MARIADB_DATABASE: ${MARIADB_DATABASE:-template}
|
|
56
|
+
MARIADB_USER: ${MARIADB_USER:-template}
|
|
57
|
+
MARIADB_PASSWORD: ${MARIADB_PASSWORD:-template}
|
|
58
|
+
MARIADB_ROOT_PASSWORD: ${MARIADB_ROOT_PASSWORD:-template-root}
|
|
59
|
+
ports:
|
|
60
|
+
- "${MARIADB_PORT:-3307}:3306"
|
|
61
|
+
volumes:
|
|
62
|
+
- mariadb_data:/var/lib/mysql
|
|
63
|
+
healthcheck:
|
|
64
|
+
test:
|
|
65
|
+
[
|
|
66
|
+
"CMD-SHELL",
|
|
67
|
+
"mariadb-admin ping -h 127.0.0.1 -u${MARIADB_USER:-template} -p${MARIADB_PASSWORD:-template}",
|
|
68
|
+
]
|
|
69
|
+
interval: 10s
|
|
70
|
+
timeout: 5s
|
|
71
|
+
retries: 10
|
|
72
|
+
start_period: 20s
|
|
73
|
+
networks:
|
|
74
|
+
- template-dev
|
|
75
|
+
|
|
76
|
+
mongo:
|
|
77
|
+
image: mongo:8
|
|
78
|
+
profiles: ["mongo"]
|
|
79
|
+
ports:
|
|
80
|
+
- "${MONGO_PORT:-27017}:27017"
|
|
81
|
+
volumes:
|
|
82
|
+
- mongo_data:/data/db
|
|
83
|
+
networks:
|
|
84
|
+
- template-dev
|
|
85
|
+
|
|
86
|
+
server:
|
|
87
|
+
build:
|
|
88
|
+
context: .
|
|
89
|
+
dockerfile: server/Dockerfile.dev
|
|
90
|
+
network: host
|
|
91
|
+
environment:
|
|
92
|
+
APP_NAME: ${SERVER_APP_NAME:-Template Server}
|
|
93
|
+
ENVIRONMENT: ${SERVER_ENVIRONMENT:-development}
|
|
94
|
+
API_PREFIX: ${SERVER_API_PREFIX:-/api/v1}
|
|
95
|
+
DATABASE_BACKEND: ${SERVER_DATABASE_BACKEND:-postgres}
|
|
96
|
+
POSTGRES_URL: ${SERVER_POSTGRES_URL:-postgresql+psycopg://template:template@postgres:5432/template}
|
|
97
|
+
MYSQL_URL: ${SERVER_MYSQL_URL:-mysql+pymysql://template:template@mysql:3306/template}
|
|
98
|
+
MARIADB_URL: ${SERVER_MARIADB_URL:-mysql+pymysql://template:template@mariadb:3306/template}
|
|
99
|
+
MONGODB_URL: ${SERVER_MONGODB_URL:-mongodb://mongo:27017}
|
|
100
|
+
MONGODB_DATABASE: ${SERVER_MONGODB_DATABASE:-template}
|
|
101
|
+
JWT_SECRET: ${SERVER_JWT_SECRET:-template-local-dev-secret}
|
|
102
|
+
JWT_ALGORITHM: ${SERVER_JWT_ALGORITHM:-HS256}
|
|
103
|
+
ACCESS_TOKEN_TTL_MINUTES: ${SERVER_ACCESS_TOKEN_TTL_MINUTES:-120}
|
|
104
|
+
BOOTSTRAP_ADMIN_EMAIL: ${SERVER_BOOTSTRAP_ADMIN_EMAIL:-admin@example.com}
|
|
105
|
+
BOOTSTRAP_ADMIN_PASSWORD: ${SERVER_BOOTSTRAP_ADMIN_PASSWORD:-change-me-admin}
|
|
106
|
+
BOOTSTRAP_ADMIN_NAME: ${SERVER_BOOTSTRAP_ADMIN_NAME:-Template Admin}
|
|
107
|
+
BOOTSTRAP_OPERATOR_EMAIL: ${SERVER_BOOTSTRAP_OPERATOR_EMAIL:-operator@example.com}
|
|
108
|
+
BOOTSTRAP_OPERATOR_PASSWORD: ${SERVER_BOOTSTRAP_OPERATOR_PASSWORD:-change-me-operator}
|
|
109
|
+
BOOTSTRAP_OPERATOR_NAME: ${SERVER_BOOTSTRAP_OPERATOR_NAME:-Template Operator}
|
|
110
|
+
CORS_ORIGINS: '${SERVER_CORS_ORIGINS:-["http://localhost:3000","http://127.0.0.1:3000","http://localhost:3001","http://127.0.0.1:3001","http://localhost:3002","http://127.0.0.1:3002","http://localhost:4000","http://127.0.0.1:4000"]}'
|
|
111
|
+
SERVER_HTTP_PORT: ${SERVER_HTTP_PORT:-8000}
|
|
112
|
+
ports:
|
|
113
|
+
- "${SERVER_HTTP_PORT:-8000}:${SERVER_HTTP_PORT:-8000}"
|
|
114
|
+
volumes:
|
|
115
|
+
- ./server:/app/server
|
|
116
|
+
depends_on:
|
|
117
|
+
postgres:
|
|
118
|
+
condition: service_healthy
|
|
119
|
+
networks:
|
|
120
|
+
- template-dev
|
|
121
|
+
|
|
122
|
+
client-landing:
|
|
123
|
+
build:
|
|
124
|
+
context: .
|
|
125
|
+
dockerfile: client/landing/Dockerfile.dev
|
|
126
|
+
network: host
|
|
127
|
+
environment:
|
|
128
|
+
PORT: ${CLIENT_LANDING_PORT:-3000}
|
|
129
|
+
VITE_API_BASE_URL: ${CLIENT_LANDING_VITE_API_BASE_URL:-http://127.0.0.1:8000/api/v1}
|
|
130
|
+
CHOKIDAR_USEPOLLING: ${CLIENT_WATCH_USE_POLLING:-false}
|
|
131
|
+
ports:
|
|
132
|
+
- "${CLIENT_LANDING_PORT:-3000}:${CLIENT_LANDING_PORT:-3000}"
|
|
133
|
+
volumes:
|
|
134
|
+
- ./client/landing:/app/client/landing
|
|
135
|
+
depends_on:
|
|
136
|
+
server:
|
|
137
|
+
condition: service_started
|
|
138
|
+
networks:
|
|
139
|
+
- template-dev
|
|
140
|
+
|
|
141
|
+
client-platform:
|
|
142
|
+
build:
|
|
143
|
+
context: .
|
|
144
|
+
dockerfile: client/platform/Dockerfile.dev
|
|
145
|
+
network: host
|
|
146
|
+
environment:
|
|
147
|
+
PORT: ${CLIENT_PLATFORM_PORT:-3001}
|
|
148
|
+
VITE_API_BASE_URL: ${CLIENT_PLATFORM_VITE_API_BASE_URL:-http://127.0.0.1:8000/api/v1}
|
|
149
|
+
CHOKIDAR_USEPOLLING: ${CLIENT_WATCH_USE_POLLING:-false}
|
|
150
|
+
ports:
|
|
151
|
+
- "${CLIENT_PLATFORM_PORT:-3001}:${CLIENT_PLATFORM_PORT:-3001}"
|
|
152
|
+
volumes:
|
|
153
|
+
- ./client/platform:/app/client/platform
|
|
154
|
+
depends_on:
|
|
155
|
+
server:
|
|
156
|
+
condition: service_started
|
|
157
|
+
networks:
|
|
158
|
+
- template-dev
|
|
159
|
+
|
|
160
|
+
client-mobile:
|
|
161
|
+
build:
|
|
162
|
+
context: .
|
|
163
|
+
dockerfile: client/mobile/Dockerfile.dev
|
|
164
|
+
network: host
|
|
165
|
+
environment:
|
|
166
|
+
PORT: ${CLIENT_MOBILE_PORT:-3002}
|
|
167
|
+
VITE_API_BASE_URL: ${CLIENT_MOBILE_VITE_API_BASE_URL:-http://127.0.0.1:8000/api/v1}
|
|
168
|
+
CHOKIDAR_USEPOLLING: ${CLIENT_WATCH_USE_POLLING:-false}
|
|
169
|
+
ports:
|
|
170
|
+
- "${CLIENT_MOBILE_PORT:-3002}:${CLIENT_MOBILE_PORT:-3002}"
|
|
171
|
+
volumes:
|
|
172
|
+
- ./client/mobile:/app/client/mobile
|
|
173
|
+
depends_on:
|
|
174
|
+
server:
|
|
175
|
+
condition: service_started
|
|
176
|
+
networks:
|
|
177
|
+
- template-dev
|
|
178
|
+
|
|
179
|
+
client-admin:
|
|
180
|
+
build:
|
|
181
|
+
context: .
|
|
182
|
+
dockerfile: client/admin/Dockerfile.dev
|
|
183
|
+
network: host
|
|
184
|
+
environment:
|
|
185
|
+
PORT: ${CLIENT_ADMIN_PORT:-4000}
|
|
186
|
+
VITE_API_BASE_URL: ${CLIENT_ADMIN_VITE_API_BASE_URL:-http://127.0.0.1:8000/api/v1}
|
|
187
|
+
CHOKIDAR_USEPOLLING: ${CLIENT_WATCH_USE_POLLING:-false}
|
|
188
|
+
ports:
|
|
189
|
+
- "${CLIENT_ADMIN_PORT:-4000}:${CLIENT_ADMIN_PORT:-4000}"
|
|
190
|
+
volumes:
|
|
191
|
+
- ./client/admin:/app/client/admin
|
|
192
|
+
depends_on:
|
|
193
|
+
server:
|
|
194
|
+
condition: service_started
|
|
195
|
+
networks:
|
|
196
|
+
- template-dev
|
|
197
|
+
|
|
198
|
+
networks:
|
|
199
|
+
template-dev:
|
|
200
|
+
driver: bridge
|
|
201
|
+
|
|
202
|
+
volumes:
|
|
203
|
+
postgres_data:
|
|
204
|
+
mysql_data:
|
|
205
|
+
mariadb_data:
|
|
206
|
+
mongo_data:
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
DEV_POSTGRES_DB=template
|
|
2
|
+
DEV_POSTGRES_USER=template
|
|
3
|
+
DEV_POSTGRES_PASSWORD=template
|
|
4
|
+
DEV_POSTGRES_PORT=15432
|
|
5
|
+
|
|
6
|
+
DEV_SERVER_HTTP_PORT=18000
|
|
7
|
+
DEV_SERVER_APP_NAME=Template Server DEV
|
|
8
|
+
DEV_SERVER_ENVIRONMENT=development
|
|
9
|
+
DEV_SERVER_API_PREFIX=/api/v1
|
|
10
|
+
DEV_SERVER_DATABASE_BACKEND=postgres
|
|
11
|
+
DEV_SERVER_POSTGRES_URL=postgresql+psycopg://template:template@postgres:5432/template
|
|
12
|
+
DEV_SERVER_MYSQL_URL=mysql+pymysql://template:template@mysql:3306/template
|
|
13
|
+
DEV_SERVER_MARIADB_URL=mysql+pymysql://template:template@mariadb:3306/template
|
|
14
|
+
DEV_SERVER_MONGODB_URL=mongodb://mongo:27017
|
|
15
|
+
DEV_SERVER_MONGODB_DATABASE=template
|
|
16
|
+
DEV_SERVER_JWT_SECRET=change-me
|
|
17
|
+
DEV_SERVER_ACCESS_TOKEN_TTL_MINUTES=120
|
|
18
|
+
DEV_SERVER_CORS_ORIGINS=https://dev-landing.example.com,https://dev-platform.example.com,https://dev-mobile.example.com,https://dev-admin.example.com
|
|
19
|
+
|
|
20
|
+
DEV_CLIENT_LANDING_PORT=13000
|
|
21
|
+
DEV_CLIENT_PLATFORM_PORT=13001
|
|
22
|
+
DEV_CLIENT_MOBILE_PORT=13002
|
|
23
|
+
DEV_CLIENT_ADMIN_PORT=14000
|
|
24
|
+
|
|
25
|
+
DEV_CLIENT_LANDING_VITE_API_BASE_URL=https://dev-api.example.com/api/v1
|
|
26
|
+
DEV_CLIENT_PLATFORM_VITE_API_BASE_URL=https://dev-api.example.com/api/v1
|
|
27
|
+
DEV_CLIENT_MOBILE_VITE_API_BASE_URL=https://dev-api.example.com/api/v1
|
|
28
|
+
DEV_CLIENT_ADMIN_VITE_API_BASE_URL=https://dev-api.example.com/api/v1
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
PROD_POSTGRES_DB=template
|
|
2
|
+
PROD_POSTGRES_USER=template
|
|
3
|
+
PROD_POSTGRES_PASSWORD=template
|
|
4
|
+
PROD_POSTGRES_PORT=25432
|
|
5
|
+
|
|
6
|
+
PROD_SERVER_HTTP_PORT=28000
|
|
7
|
+
PROD_SERVER_WORKERS=4
|
|
8
|
+
PROD_SERVER_APP_NAME=Template Server PROD
|
|
9
|
+
PROD_SERVER_ENVIRONMENT=production
|
|
10
|
+
PROD_SERVER_API_PREFIX=/api/v1
|
|
11
|
+
PROD_SERVER_DATABASE_BACKEND=postgres
|
|
12
|
+
PROD_SERVER_POSTGRES_URL=postgresql+psycopg://template:template@postgres:5432/template
|
|
13
|
+
PROD_SERVER_MYSQL_URL=mysql+pymysql://template:template@mysql:3306/template
|
|
14
|
+
PROD_SERVER_MARIADB_URL=mysql+pymysql://template:template@mariadb:3306/template
|
|
15
|
+
PROD_SERVER_MONGODB_URL=mongodb://mongo:27017
|
|
16
|
+
PROD_SERVER_MONGODB_DATABASE=template
|
|
17
|
+
PROD_SERVER_JWT_SECRET=change-me
|
|
18
|
+
PROD_SERVER_ACCESS_TOKEN_TTL_MINUTES=120
|
|
19
|
+
PROD_SERVER_CORS_ORIGINS=https://landing.example.com,https://platform.example.com,https://mobile.example.com,https://admin.example.com
|
|
20
|
+
|
|
21
|
+
PROD_CLIENT_LANDING_PORT=23000
|
|
22
|
+
PROD_CLIENT_PLATFORM_PORT=23001
|
|
23
|
+
PROD_CLIENT_MOBILE_PORT=23002
|
|
24
|
+
PROD_CLIENT_ADMIN_PORT=24000
|
|
25
|
+
|
|
26
|
+
PROD_CLIENT_LANDING_VITE_API_BASE_URL=https://api.example.com/api/v1
|
|
27
|
+
PROD_CLIENT_PLATFORM_VITE_API_BASE_URL=https://api.example.com/api/v1
|
|
28
|
+
PROD_CLIENT_MOBILE_VITE_API_BASE_URL=https://api.example.com/api/v1
|
|
29
|
+
PROD_CLIENT_ADMIN_VITE_API_BASE_URL=https://api.example.com/api/v1
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Infra Compose
|
|
2
|
+
|
|
3
|
+
루트 [compose.yml](../../compose.yml)은 템플릿 저장소의 canonical dev-focused runtime baseline이다.
|
|
4
|
+
이 디렉터리는 dedicated host나 분리된 환경 스택이 필요할 때 사용하는 DEV(개발계)/PROD overlay와 env example을 유지한다.
|
|
5
|
+
|
|
6
|
+
파일:
|
|
7
|
+
|
|
8
|
+
- `dev.yml`: dedicated DEV(개발계) host/reference stack
|
|
9
|
+
- `prod.yml`: dedicated PROD/reference stack
|
|
10
|
+
- `.env.dev.example`: DEV(개발계) 변수 예시
|
|
11
|
+
- `.env.prod.example`: PROD 변수 예시
|
|
12
|
+
|
|
13
|
+
사용:
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
cp .env.example .env
|
|
17
|
+
docker compose up --build
|
|
18
|
+
|
|
19
|
+
cp infra/compose/.env.dev.example infra/compose/.env.dev
|
|
20
|
+
docker compose --env-file infra/compose/.env.dev -f infra/compose/dev.yml up -d --build
|
|
21
|
+
|
|
22
|
+
cp infra/compose/.env.prod.example infra/compose/.env.prod
|
|
23
|
+
docker compose --env-file infra/compose/.env.prod -f infra/compose/prod.yml up -d --build
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
주의:
|
|
27
|
+
|
|
28
|
+
- 루트 `compose.yml`은 clone 직후 4개 frontend surface, `server`, 기본 `postgres`를 함께 올리는 dev-focused baseline이다.
|
|
29
|
+
- optional DB adapter 검증은 root compose profile로 수행한다: `mysql`, `mariadb`, `mongo`.
|
|
30
|
+
- `infra/compose/dev.yml`, `infra/compose/prod.yml`은 dedicated host/runtime split이 필요할 때 쓰는 overlay이며, root compose baseline을 대체하는 문서 기준선은 아니다.
|
|
31
|
+
- provider-first canonical delivery split은 `AWS edge/domain -> OpenStack backend compute -> AWS data plane`이고, 세부 구조는 `infra/terraform/README.md`를 기준으로 설명한다.
|
|
32
|
+
- `VITE_API_BASE_URL`은 컨테이너 내부 DNS가 아니라 브라우저가 도달 가능한 API URL이어야 한다.
|
|
33
|
+
- 포트 역할은 root compose baseline과 같은 순서를 따른다: landing, platform, mobile, admin, server/http.
|
|
34
|
+
- PROD 웹 앱은 `pnpm build + pnpm preview`로 기동한다.
|
|
35
|
+
- OpenStack에서 자동 배포까지 묶고 싶으면 `infra/terraform/openstack/server` 또는 lower-level `openstack/dev`, `openstack/prod` root를 사용한다.
|