Commit Graph

6 Commits

Author SHA1 Message Date
Ubuntu a6bf9b3891 fix(azure): fix PostgreSQL SKU format and ACR login resource group
- infra.bicep: correct SKU format from B_Standard_B1ms to Standard_B1ms
  (Azure Flexible Server uses Standard_* prefix, not B_*); update tier
  detection logic accordingly (contains '_B' -> Burstable)
- 2-build-deploy.sh: add --resource-group to az acr login to avoid
  accidentally matching an ACR with the same name in a different RG
- config.sh.example: update POSTGRES_SKU default to Standard_B1ms

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-05 08:17:06 +00:00
Ubuntu c032580c3b fix(azure): fix Bicep syntax errors in infra.bicep and container-app.bicep
- infra.bicep: remove escaped apostrophes from @description strings (BCP071),
  remove unsupported @sensitive() decorator (BCP057), rename output
  storageAccountName -> storageAccountNameOut to avoid collision with param,
  rename postgresAdminUser output -> postgresAdminUserOut
- container-app.bicep: remove unused fileShareName param (no-unused-params)
- 1-infra.sh: update output key storageAccountName -> storageAccountNameOut
- 2-build-deploy.sh: remove fileShareName param (no longer in container-app.bicep)

Both files now compile clean (az bicep build passes with only expected
outputs-should-not-contain-secrets warnings).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-05 07:47:06 +00:00
Ubuntu 9ee3dc1d59 feat(azure): allow reusing existing Storage Account via storageAccountName param
- infra.bicep: add storageAccountName param (empty = auto-generate
  '${projectName}store'); effectiveStorageAccountName var resolves the
  final name; Bicep reconciles the existing account idempotently without
  touching other file shares (caddydata, neo4jdata, etc.)
- 1-infra.sh: forward STORAGE_ACCOUNT_NAME (optional) to Bicep
- config.sh.example: document Opció A (existing account, e.g. stgraphiti16852)
  vs Opció B (new account); clarify which vars are inputs vs outputs of 1-infra.sh

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-05 07:33:30 +00:00
Ubuntu 842cf09a10 feat(azure): add PostgreSQL Flexible Server + Azure Files persistent storage
- infra.bicep: Storage Account + File Share (mirofish-uploads, 100GB SMB),
  envStorage to register share in Container Apps Env, PostgreSQL Flexible
  Server (v16, 32GB) with mirofish database and Azure-services firewall rule;
  new secure outputs: storageConnectionString, databaseUrl, storageAccountKey
- container-app.bicep: storageConnectionString/databaseUrl/storageAccountName/
  fileShareName params; volume mount at /mnt/uploads (Azure Files);
  OASIS_SIMULATION_DATA_DIR + UPLOAD_FOLDER + STORAGE_TYPE env vars set
  conditionally based on whether storage is configured
- 1-infra.sh: POSTGRES_ADMIN_PASSWORD required, register Storage/PostgreSQL
  providers, pass new Bicep params, print generated DATABASE_URL and
  STORAGE_CONNECTION_STRING for pasting into config.sh
- 2-build-deploy.sh: DATABASE_URL + STORAGE_CONNECTION_STRING required and
  forwarded to container-app.bicep
- config.sh.example: add POSTGRES_ADMIN_PASSWORD, POSTGRES_ADMIN_USER,
  POSTGRES_SKU, STORAGE_CONNECTION_STRING, STORAGE_ACCOUNT_NAME,
  FILE_SHARE_NAME, DATABASE_URL
- pyproject.toml + uv.lock: add psycopg2-binary>=2.9.9 (PostgreSQL driver)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-04 23:37:31 +00:00
Ubuntu f9b5f79747 chore(azure): remove Log Analytics Workspace from infra
Simplifies infrastructure: ACR + Container Apps Environment only.
Log Analytics can be added later if observability is needed.
Update INSTALL.md accordingly.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-24 19:30:36 +00:00
Ubuntu ffe6c537d0 feat(azure): add infra + build/deploy scripts for Azure Container Apps
Split Bicep into infra.bicep (one-time: ACR + Log Analytics + Env) and
container-app.bicep (per-deploy: Container App with ACR auth).
Add 1-infra.sh and 2-build-deploy.sh shell scripts with config.sh.example
covering all .env variables. Gitignore azure/config.sh to prevent
secret leakage.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-24 19:28:21 +00:00