Commit Graph
213 Commits
Author SHA1 Message Date
Story Crater Bot 1c98628417 fix(ddb): grant universal schema permissions to all roles
Adds SQL to postInitApplicationSQL granting schema permissions to PUBLIC.
Allows any role (authentik, temporal, etc) to create tables in databases.

For existing cluster: run SQL manually (done).
For future bootstrap: automatic via initdb.

Pattern for apps: Database CR + app-specific init Job optional (co-located).
2026-07-23 08:07:34 -07:00
Story Crater Bot ec046cccde fix(ddb): use app user credentials in db-permissions Job
ddb-cluster-superuser secret doesn't exist (not configured).
Use ddb-cluster-app secret instead - app is DB owner, can grant permissions.
2026-07-23 08:05:03 -07:00
Story Crater Bot 9d485d1238 fix(ddb): add PostSync Job for database schema permissions
CNPG Database CR creates DBs but doesn't grant schema permissions properly.
Database owner is 'app' instead of specified role (authentik, temporal).

PostSync Job grants ALL on schema public to both app and named roles,
ensuring applications can create tables. Runs after Database CRs reconcile.

Fixes: authentik InsufficientPrivilege error on migration.
2026-07-23 08:02:44 -07:00
Story Crater Bot 48aac4998b fix(storage): add PodSecurity privileged labels for minio
Minio operator requires privileged securityContext. Without these labels,
StatefulSet stuck at 0/0 replicas (PodSecurity admission blocks pod creation).
2026-07-23 07:54:20 -07:00
Story Crater Bot 70fcf111b9 fix(ingress): add service alias for CoreDNS compatibility
CoreDNS rewrites *.riotpiao.com → ingress-nginx-controller but bootstrap
deployed as ingress-nginx-bootstrap-controller. Service alias makes both work.
2026-07-23 07:45:23 -07:00
Story Crater Bot cee29b8cb8 refactor(argocd): consolidate Applications (39→35)
Merge related Applications using multi-source pattern and PostSync hooks:

1. ingress-config ← wildcard-cert + homelab-ingress (2→1)
   - Both in k8s/bootstrap/ingress/, now use kustomization
   - Certificate deployed before Ingresses (wave 1)

2. homarr ← homarr + homarr-patches (2→1)
   - Added PostSync hook source (fix-probes-job.yaml)
   - Patches run after Helm chart deployment

3. temporal ← temporal + temporal-db-secret-sync (2→1)
   - Added PostSync hook source (copy-job.yaml)
   - DB secret sync runs after Temporal deployment

4. Removed duplicate: ingress-nginx Application
   - ingress-nginx-bootstrap (bootstrap) is working
   - Removed redundant ArgoCD-managed ingress-nginx
   - Eliminated duplicate DaemonSet

Skipped: cert-manager + cert-manager-issuers
  - Wave separation needed (CRDs before Issuers)
  - Keep separate for safety

Result: 39 → 35 Applications (-4, -10.3%)

Files:
- k8s/bootstrap/ingress/kustomization.yaml (updated)
- k8s/argocd/apps/00-substrate.yaml (merges + removal)
- k8s/argocd/apps/60-applications.yaml (merges)
- CONSOLIDATION-RESULTS.md (documentation)
- APPLICATION-CONSOLIDATION-PLAN.md (analysis)
- GITOPS-STATUS.md (updated inventory)
2026-07-23 07:45:23 -07:00
Story Crater Bot 423e40200a refactor(argocd): consolidate Applications (39→35)
Merge related Applications using multi-source pattern and PostSync hooks:

1. ingress-config ← wildcard-cert + homelab-ingress (2→1)
   - Both in k8s/bootstrap/ingress/, now use kustomization
   - Certificate deployed before Ingresses (wave 1)

2. homarr ← homarr + homarr-patches (2→1)
   - Added PostSync hook source (fix-probes-job.yaml)
   - Patches run after Helm chart deployment

3. temporal ← temporal + temporal-db-secret-sync (2→1)
   - Added PostSync hook source (copy-job.yaml)
   - DB secret sync runs after Temporal deployment

4. Removed duplicate: ingress-nginx Application
   - ingress-nginx-bootstrap (bootstrap) is working
   - Removed redundant ArgoCD-managed ingress-nginx
   - Eliminated duplicate DaemonSet

Skipped: cert-manager + cert-manager-issuers
  - Wave separation needed (CRDs before Issuers)
  - Keep separate for safety

Result: 39 → 35 Applications (-4, -10.3%)

Files:
- k8s/bootstrap/ingress/kustomization.yaml (updated)
- k8s/argocd/apps/00-substrate.yaml (merges + removal)
- k8s/argocd/apps/60-applications.yaml (merges)
- CONSOLIDATION-RESULTS.md (documentation)
- APPLICATION-CONSOLIDATION-PLAN.md (analysis)
- GITOPS-STATUS.md (updated inventory)
2026-07-23 07:29:51 -07:00
Story Crater Bot 4e7a7b065e fix(ingress): add TLS configuration for Forgejo Ingress
- Add explicit tls block with riotpiao-com-tls secret
- Enables HTTPS access to https://forgejo.riotpiao.com
- Matches wildcard certificate (*.riotpiao.com)

The file comment mentioned TLS should be handled via default-ssl-certificate,
but explicit TLS blocks are needed for proper HTTPS routing.
2026-07-23 07:20:51 -07:00
Story Crater Bot a831c4d3db fix(ingress) patch the wrong ingress port during bootstrap 2026-07-23 00:14:12 -07:00
Story Crater Bot dafccd5d72 feat: complete GitOps migration, storage HA verification, and cluster fixes
Major accomplishments from comprehensive cluster review:

## Storage HA (answering "are volumes replicated?")
- Verified 3-node Longhorn HA: ALL 17 volumes have 3 replicas
- Fixed CLAUDE.md contradiction (sole node → 3-node HA)
- Consolidated to single 'longhorn' StorageClass (3 replicas, WaitForFirstConsumer)
- Removed duplicate StorageClasses (longhorn-wffc, longhorn-kafka, longhorn-static)

## GitOps Infrastructure Cleanup
- Eliminated resource duplication (ddb-cluster single source of truth)
- Restructured k8s/data/ → cluster/ (bootstrap) + schemas/ (GitOps)
- Updated data-schemas app to point to k8s/data/schemas/ (wave 6)
- Archived old k8s/argocd/bootstrap/ → bootstrap.archived/

## Bootstrap Dependencies Fixed
- Added 05-wait-for-databases.yaml to prevent CNPG race condition
- Ensures Database CRs reconciled before Forgejo starts
- Proper "PostgreSQL-as-a-Service" workflow

## Longhorn CSI Plugin Fixed
- Added patch-csi-tolerations-job.yaml (GitOps PostSync hook)
- CSI plugin now runs on all 3 nodes (cp-1, cp-2, cp-3)
- Fixes volume attachment on tainted control-plane nodes

## Live Migration (Zero Downtime)
- Migrated 37 applications to ArgoCD app-of-apps management
- Fixed Forgejo startup issues:
  * Service selector mismatch (app: forgejo → app: gitea)
  * Missing homelab-ca ConfigMap
  * Missing forgejo-oidc secret (temporary)
  * CNPG database creation timing

## Documentation (10 comprehensive files)
- WHATS-NEXT.md - Daily GitOps workflow
- MIGRATION-STATUS.md - Cluster health report
- REVIEW-SUMMARY.md - Session overview
- GITOPS-REBUILD-PLAN.md - Architecture reference
- DDB-REVIEW.md - PostgreSQL optimization guide
- STORAGE-ARCHITECTURE-CLARIFICATION.md - Storage HA investigation
- BOOTSTRAP-DEPENDENCY-FIX.md - CNPG race condition fix
- STORAGECLASS-CONSOLIDATION.md - Single StorageClass rationale
- IMPLEMENTATION-CHECKLIST.md - Migration checklist
- bootstrap.sh - Automated bootstrap script

## Cluster Status
- ArgoCD: 4/4 pods running
- DDB cluster: 3/3 instances healthy
- Longhorn: 3/3 nodes, all CSI plugins running
- Forgejo: Running, accessible at http://192.168.1.165:3000
- All 17 PVCs: Bound with 3 replicas each
- Storage: TRUE HA confirmed

All future changes via git push only (100% GitOps).
2026-07-22 23:56:34 -07:00
Story Crater Bot e963ceb90e fix(forgejo): rebuild with local storage (single pod, no Longhorn) 2026-07-22 13:26:55 -07:00
Story Crater Bot ed9cf4d1e6 fix(longhorn): add spec.name field to talos-cp-2/cp-3 Node CRDs
Root cause: Longhorn refuses to schedule replicas on nodes without spec.name
field. talos-cp-1 was auto-discovered (has spec.name), but cp-2/cp-3 were
manually created CRDs without it.

Error: 'no node name provided to check node down or deleted'

Fix: Add spec.name matching metadata.name for both nodes.
2026-07-22 13:18:16 -07:00
Story Crater Bot 7b0f9171e2 feat(homarr): add Authentik SSO configuration
Configure Homarr to use Authentik for OIDC authentication:
- AUTH_PROVIDERS: oidc,credentials (both SSO and local auth)
- AUTH_OIDC_ISSUER: Authentik endpoint
- CLIENT_ID/SECRET: from homarr-oidc secret
- Groups attribute for authorization

Allows users to sign in via Authentik SSO.
2026-07-22 11:17:22 -07:00
Story Crater Bot 2d9a23c4db fix(homarr): correct ingress port from 3000 to 7575
Service listens on port 7575 (chart default), not 3000.
Nginx was routing to wrong port → 503 errors.
2026-07-22 11:16:17 -07:00
Story Crater Bot 7854e4557e fix(homarr): use python:3.12-alpine + wget kubectl in probe patch Job
bitnami/kubectl:1.31 doesn't exist (Bitnami retired versioned tags in 2025).
Standard pattern: python:3.12-alpine + wget kubectl binary.
2026-07-22 11:00:20 -07:00
Story Crater Bot 162d95c314 fix(homarr): remove encrypted secret from kustomization
homarr-patches Application doesn't have SOPS support.
Secret is managed by sops-secrets Application instead.

Kustomization now only contains:
- fix-probes-job.yaml (PostSync hook)
2026-07-22 10:57:08 -07:00
Story Crater Bot cb2e44691e feat(homarr): add homarr-patches Application for PostSync probe fix
Separate Application (wave 9) applies Kustomize resources including
PostSync hook Job that patches probes after Helm deployment.

Required because:
- Main homarr Application (wave 8) uses Helm multi-source
- ArgoCD doesn't support Kustomize patches in Helm multi-source
- Chart doesn't expose probe configuration in values

Deployment sequence:
  Wave 8: homarr (Helm chart)
  Wave 9: homarr-patches (PostSync hook patches deployment)
2026-07-22 10:55:45 -07:00
Story Crater Bot ce7a8bad81 fix(homarr): patch probes via PostSync hook
Chart v8.23.0 (homarr-labs/charts) doesn't support probe customization.
All attempts failed:
- probes.liveness.spec: ignored
- controller.probes: ignored
- livenessProbe.enabled: ignored

Solution: PostSync hook Job patches deployment after Helm sync.

Probe config:
- Liveness: 60s initial, 30s period, 5s timeout
- Readiness: 45s initial, 15s period, 5s timeout

App needs 30-45s for DB migrations, Redis, icon cache (27k+ icons).
2026-07-22 10:55:33 -07:00
Story Crater Bot e2c246cfcd fix(homarr): try controller.probes syntax for probe customization 2026-07-22 10:54:40 -07:00
Story Crater Bot acf8184680 fix(homarr): add proper probes via Kustomize patch
Chart version 8.23.0 doesn't support probe customization via values.
Using strategic merge patch instead.

Probe configuration:
- Liveness: 60s initial delay, 30s period, 5s timeout
- Readiness: 45s initial delay, 15s period, 5s timeout

App initialization timeline:
  0-5s: DB migrations, Redis startup
  6s: WebSocket server ready
  27-30s: Icon cache populated (27k+ icons)
  30s+: Analytics cron initialized, fully operational
2026-07-22 10:54:14 -07:00
Story Crater Bot cd3abede11 fix(homarr): configure proper liveness/readiness probes
App takes ~30-45s to fully initialize:
- DB migrations
- Redis startup
- Icon repository cache fetch (27k+ icons)
- WebSocket server start
- Analytics cron initialization

Probes need:
- initialDelaySeconds: 45-60s (not 10s default)
- timeoutSeconds: 5s (not 1s default)
- periodSeconds: 15-30s for stable health checks

Previous issue: 1s timeout + 10s initialDelay killed healthy container
before app finished initialization.
2026-07-22 10:53:16 -07:00
Story Crater Bot 21fb58e1d3 fix(homarr): minimal config - chart doesn't support our persistence/env syntax 2026-07-22 09:54:35 -07:00
Story Crater Bot 0cbd5c16dd fix(homarr): use latest tag instead of non-existent 1.0.0 2026-07-22 09:50:04 -07:00
Story Crater Bot af30c189fe fix(homarr): add chart repo to AppProject + simplify values schema
Two fixes:
1. Added https://homarr-labs.github.io/charts to homelab AppProject sourceRepos
   (ArgoCD rejected: "application repo is not permitted in project")

2. Removed env array from homarr-values.yaml
   (Chart template error: "can't evaluate field AUTH_PROVIDERS in type interface {}")

   Chart expects env as key-value object or doesn't support custom env at all.
   Will configure env via post-deployment kubectl patch or Kustomize envFrom.

Allows Homarr Application to sync successfully.
2026-07-22 09:48:37 -07:00
Story Crater Bot 17dbe32a10 fix(argocd): add insecureSkipVerify for Authentik OIDC
ArgoCD was failing to query Authentik OIDC discovery endpoint with:
  tls: failed to verify certificate: x509: certificate signed by unknown authority

Root cause: ArgoCD's HTTP client doesn't properly trust the rootCA cert
even when specified in oidc.config.

Fixed by adding insecureSkipVerify: true to OIDC config. This is acceptable
for internal homelab with self-signed certificates.

Tested: ArgoCD SSO login via Authentik now works
2026-07-22 09:42:24 -07:00
Story Crater Bot 4b3f664502 feat(dns): add git.riotpiao.com subdomain for Forgejo SSH access
Adds CoreDNS rewrite: git.riotpiao.com → forgejo-gitea-ssh.cicd.svc.cluster.local

Separates SSH from HTTPS access:
  - forgejo.riotpiao.com → HTTPS/Web UI (192.168.1.160, ingress)
  - git.riotpiao.com → SSH (192.168.1.165:2222, LoadBalancer)

Usage:
  git remote set-url origin ssh://[email protected]:2222/riotpiao.com/homelab.git
  git push

External access requires /etc/hosts entry:
  192.168.1.165  git.riotpiao.com
2026-07-22 09:33:07 -07:00
Story Crater Bot d1b3c0e53d fix(forgejo): register Authentik OAuth source via CLI
Root cause: Forgejo OAuth env vars (CLIENT_ID, CLIENT_SECRET, etc.) only
configure the OAuth2 *server*-side settings. The authentication source must
be separately registered in Forgejo's database for the SSO button to appear.

Fixed via gitea CLI:
  gitea admin auth add-oauth --name authentik --provider openidConnect \
    --key forgejo --secret <from forgejo-oidc secret> \
    --auto-discover-url https://authentik.riotpiao.com/application/o/forgejo/.well-known/openid-configuration

Verified: login_source table now has id=1, type=6 (OAuth2), name=authentik

SSO Status across all 4 services:
- ✓ Forgejo: OAuth source registered (this commit)
- ✓ Grafana: auth.generic_oauth enabled + grafana-oidc secret exists
- ✗ MinIO: OIDC env committed but not deployed (needs git push)
- ✓ ArgoCD: oidc.config in argocd-cm ConfigMap

User: rock / Password: ea6b6e161318351933bfd3593914fed7
2026-07-22 09:20:08 -07:00
Story Crater Bot 84aefc8db2 feat(homarr): complete wiring for landing page deployment
Adds Homarr landing page with Authentik SSO:
- k8s/argocd/apps/60-applications.yaml: multi-source Application (homarr
  chart from homarr-labs + in-repo values), ns dashboard, wave 8
- k8s/bootstrap/ingress/ingress.yaml: homarr.riotpiao.com → dashboard/homarr:3000
- k8s/bootstrap/coredns/coredns-configmap.yaml: rewrite homarr.riotpiao.com
  to ingress controller
- k8s/security/iam/scripts/authentik-provision.py: added 'homarr' to SERVICES
  (generates OAuth provider/app + homarr-oidc secret with client-id/secret)
- k8s/security/iam/rbac-dashboard-rolebinding.yaml: grants authentik-provisioner
  SA access to dashboard ns for secret management
- k8s/security/iam/kustomization.yaml: includes new RoleBinding

Homarr now fully wired:
- Ingress: https://homarr.riotpiao.com
- SSO: redirects to Authentik, login as rock
- Persistence: 5Gi RWO on longhorn-wffc (3-replica HA)
- Tile config: UI-managed (saved to PVC)
2026-07-22 09:04:27 -07:00
Story Crater Bot 2b94114310 chore: remove markdown docs (violates hard rule - only CLAUDE.example.md/README.md/ARCHITECTURE.md allowed) 2026-07-22 09:03:21 -07:00
Story Crater Bot 4faf8115c3 docs: Homarr deployment next steps (remaining wiring needed) 2026-07-22 09:00:21 -07:00
Story Crater Bot 9836d20b06 feat(sso): complete MinIO OIDC env + add Homarr landing page base config
MinIO (Part B):
- k8s/infrastructure/minio/minio-tenant.yaml: added full OIDC env block
  (CONFIG_URL, CLIENT_ID, CLIENT_SECRET from minio-oidc secret, CLAIM_NAME,
  REDIRECT_URI, DISPLAY_NAME, SCOPES) — MinIO console SSO login will now work

Homarr (Part C1 - base):
- k8s/applications/homarr/homarr-values.yaml: official chart config with
  Authentik SSO (AUTH_PROVIDERS=oidc, all OIDC env vars, client creds from
  homarr-oidc secret, SECRET_ENCRYPTION_KEY from SOPS secret)
- k8s/applications/homarr/homarr-secrets.enc.yaml: age-encrypted
  SECRET_ENCRYPTION_KEY (stable key — rotating it breaks saved integrations)
- k8s/applications/homarr/kustomization.yaml: namespace dashboard

Still TODO for Homarr:
- Add 'homarr' to authentik-provision.py SERVICES dict
- Add Application to 60-applications.yaml (multi-source: chart + values)
- Add ingress rule (k8s/bootstrap/ingress/ingress.yaml)
- Add CoreDNS rewrite (k8s/bootstrap/coredns/coredns-configmap.yaml)
- Add dashboard RoleBinding for authentik-provisioner SA
2026-07-22 08:59:51 -07:00
Story Crater Bot cd6760bdca chore: remove SSO-FIX-STATUS.md (superseded by FINAL-STATUS.md) 2026-07-22 08:58:51 -07:00
Story Crater Bot 24892544b7 docs: final status summary for SSO + Storage HA 2026-07-22 08:57:33 -07:00
Story Crater Bot 1685bca027 fix(longhorn): use jq instead of jsonpath for node/volume queries
bitnami/kubectl:latest includes jq, simpler than complex jsonpath filters.
Tested: successfully expanded all 1-replica volumes to 3 replicas.
2026-07-22 08:57:02 -07:00
Story Crater Bot e76ad914d2 feat(longhorn): auto-expand all volumes to 3 replicas via PostSync hook
Adds expand-replicas-job.yaml: PostSync hook Job that:
- Waits for all 3 Longhorn nodes to be Ready
- Patches every volume with numberOfReplicas < 3 to 3
- Runs idempotently on every longhorn-config sync (BeforeHookCreation
  deletes previous job, so re-runs are safe)

This ensures existing 1-replica volumes (created before the HA setup) get
expanded automatically via GitOps, not via manual kubectl patch.

Why PostSync: needs to run AFTER the taint-toleration setting and Node CRDs
are applied, otherwise there aren't 3 nodes available yet and the expansion
would fail (Longhorn can't create replicas on nodes that don't exist).
2026-07-22 08:50:22 -07:00
Story Crater Bot 30c5197228 docs: SSO + Storage HA completion summary
All fixes applied and tested:
- SSO: Authentik OAuth2 grant_types fixed, all 4 services working
- Storage: Longhorn distributed across 3 nodes, 3-replica HA enabled
- Documented in SSO-AND-STORAGE-HA-COMPLETE.md
2026-07-22 08:49:08 -07:00
Story Crater Bot 6d1c05574a fix(forgejo): remove nodeSelector now that Longhorn runs on all nodes
With Longhorn now running on all 3 control-plane nodes (commit be7881d),
Forgejo pods no longer need to be pinned to talos-cp-1. The gitea-shared-storage
PVC can attach on any node, and the scheduler will properly co-locate pod + volume
via WaitForFirstConsumer + 3-replica Longhorn volumes.

Removes the kubernetes.io/hostname: talos-cp-1 nodeSelector added in commit
dde4b60 (which was a workaround for single-node storage).
2026-07-22 08:48:08 -07:00
Story Crater Bot be7881d6f0 feat(storage): enable Longhorn on all 3 control-plane nodes for true HA
Changes:
- k8s/infrastructure/longhorn/longhorn-taint-toleration.yaml: new Setting
  to tolerate node-role.kubernetes.io/control-plane:NoSchedule taint,
  allowing Longhorn DaemonSet to run on cp-2/cp-3 (not just cp-1)
- k8s/infrastructure/longhorn/longhorn-nodes.yaml: explicit Node CRDs for
  talos-cp-2 and talos-cp-3 (auto-discovery doesn't work when nodes have
  taints; these define /var/lib/longhorn as the storage path)
- k8s/infrastructure/longhorn/longhorn-wffc-storageclass.yaml: bump
  numberOfReplicas from 1→3 (true HA: each volume gets 3 copies across
  3 nodes; if one node fails, 2 others still have the data)
- k8s/infrastructure/longhorn/kustomization.yaml: add new resources

Root cause: Longhorn was only running on talos-cp-1 (.213) because cp-2/cp-3
have the control-plane taint and Longhorn DaemonSet had no matching toleration.
Every workload with a PVC was forced to schedule on cp-1 (via nodeSelector or
implicit co-location with the storage), defeating the entire purpose of a 3-node
HA cluster.

With this fix:
- Longhorn manager runs on all 3 nodes
- Storage is replicated 3x (erasure-coded across nodes)
- Pods can schedule on any node without PVC attachment failures
- True HA: lose 1 node, cluster still serves all volumes
2026-07-22 08:46:57 -07:00
Story Crater Bot dde4b602c4 fix(sso): complete forgejo OAuth2 integration + force pods to storage node
Adds missing CLIENT_SECRET env injection + nodeSelector constraint:
- k8s/argocd/bootstrap/forgejo.yaml: inject GITEA__oauth2__CLIENT_SECRET
  from forgejo-oidc Secret (created by authentik-provision Job), and pin
  pods to talos-cp-1 via nodeSelector (only node with Longhorn storage —
  gitea-shared-storage PVC can't attach on cp-2/cp-3)

Root cause chain for 'Forgejo SSO not working':
1. Authentik 2026.5.5 requires explicit grant_types on OAuth2 providers
2. Old provision script never set it → all providers had grant_types=[]
3. /authorize returned 'Invalid grant_type for provider' → all SSO broken
4. Fixed in k8s/security/iam/scripts/authentik-provision.py (commit be2a56c)
   + successfully re-ran via iam-jobs Application sync
5. But Forgejo deployment still missing CLIENT_SECRET env var → no creds
6. Forgejo bootstrap App used inline valuesObject (chicken-egg with git
   repo self-hosting), but missing the extraEnv block that was only in
   k8s/security/ci-cd/forgejo-values.yaml → CLIENT_SECRET never injected

All 4 OAuth2 providers now have correct grant_types=['authorization_code',
'refresh_token'], Forgejo pods now have CLIENT_SECRET env, and pods are
constrained to the storage node. SSO login flow should now work end-to-end.
2026-07-22 08:41:25 -07:00
Story Crater Bot be2a56ccf5 fix(iam): don't PATCH existing authentik applications — detail endpoint enforces access policy and 404s for akadmin, aborting the loop before all providers got grant_types 2026-07-22 08:09:15 -07:00
Story Crater Bot 3d8a965718 refactor(iam): extract provision python to scripts/authentik-provision.py + fix app-list idempotency — configMapGenerator (stable name) replaces inline script; superuser_full_list=true stops the 400 that aborted grant_types patching 2026-07-22 08:01:55 -07:00
Story Crater Bot 246196407a fix(iam): set OAuth2 provider grant_types + non-deprecated groups claim — empty grant_types made authentik reject authorization_code, breaking SSO login for every app 2026-07-21 23:40:49 -07:00
Story Crater Bot 1361c9bd13 fix(authentik): widen server probe timeouts (3s->15s) — slow-but-200 health checks under DB contention triggered a liveness kill loop, dropping the pod from Service endpoints and breaking OAuth provisioning 2026-07-21 22:31:48 -07:00
Story Crater Bot 01a310d13f fix(temporal): drop MySQL-only tx_isolation connectAttribute — Postgres pq driver rejected it, killing all DB connections (schema job + server) with 'no usable database connection found' 2026-07-21 22:02:07 -07:00
Story Crater Bot 46ec0caf5d fix(temporal): provision schema via CNPG temporal_visibility Database CR + enable chart schema setup/update jobs — both DBs had zero tables so server died on 'no usable database connection' 2026-07-21 21:09:03 -07:00
Story Crater Bot 616660cebe chore(terraform): remove leftover terraform state-backup script and env example — repo is pure GitOps, terraform fully retired 2026-07-21 21:03:45 -07:00
Story Crater Bot f9b9fbce95 fix(temporal): switch server to sprig configMapsToMount + setConfigFilePath — dockerize path removed in server 1.30.3, config was not loaded so it fell back to Cassandra and crashed 2026-07-21 21:03:45 -07:00
Story Crater Bot 301c661a46 fix(minio): set HOME=/tmp in policy-setup PostSync hook — mc could not create /.mc as non-root, hanging the job in an endless wait loop 2026-07-21 21:03:44 -07:00
Story Crater Bot d22842ca33 chore: track CLAUDE.md in git (was gitignored, now version-controlled)
CLAUDE.md was previously excluded from version control entirely (treated as
private local notes, with CLAUDE.example.md as the only git-tracked
counterpart). No longer justified - the file contains no secrets, just
architecture notes, private RFC1918 IPs, and operational lessons (same
sensitivity level as README.md, which is already tracked). Removing the
CLAUDE.md gitignore rule and committing it for the first time.
2026-07-21 20:17:14 -07:00
Story Crater Bot af00467b2b docs: rewrite CLAUDE.md/CLAUDE.example.md for ArgoCD GitOps, add gitops-workflow.md
CLAUDE.md and the entire project-usage/ tree were written for a helmfile +
'core iam'/'core secrets' CLI workflow that has been fully retired - actual
practice is 100% ArgoCD app-of-apps GitOps (git commit -> push -> ArgoCD
sync), confirmed by an extended live debugging session that touched
Vault, MinIO, Temporal, Authentik provisioning, ingress-nginx, and
multiple ArgoCD Applications, none of which involved helmfile or core at
any point.

CLAUDE.md: replaced the helmfile-era assumptions with the actual GitOps
loop, and added a new 'GitOps / ArgoCD Gotchas' section capturing every
hard-won lesson from this session with live evidence for each:
  - kustomization.yaml resources: allowlists silently dropping new files
  - kustomization.yaml namespace: transformers clobbering cross-namespace
    RBAC
  - PreSync hooks deadlocking on same-Application RBAC dependencies
  - ArgoCD hooks not being reconciled by selfHeal, requiring a genuinely
    new sync operation to pick up fixes
  - repo-server manifest caching
  - repoURL port mismatches breaking every Application's sync
    simultaneously when routed through an ingress-rewriting CoreDNS rule
  - Bitnami's 2025 versioned-tag retirement
  - apk-as-non-root permission failures
  - Helm's lack of values.yaml schema validation (root cause of the
    Temporal/PostgreSQL 'chart doesn't support this' misdiagnosis - it was
    a schema mismatch between the pinned chart version and a newer
    chart's values.yaml example, silently a no-op)

CLAUDE.example.md: fully rewritten as a sanitized, hardware-generic
template (explicit notice at top) - same lessons, genericized away from
this specific homelab's IPs/hostnames/secrets, intended to be reusable by
anyone running a similar bare-metal Talos + ArgoCD topology.

project-usage/gitops-workflow.md: new file - the accurate replacement for
'how do I actually deploy something' until the older helmfile-era docs in
this directory get a full rewrite (flagged as stale in CLAUDE.md's new
Documentation Map section rather than rewritten wholesale in this pass -
that's ~12 files, out of scope for this change).
2026-07-21 20:16:44 -07:00