Commit Graph

17 Commits

Author SHA1 Message Date
WorkClub Automation 86c7b0d46d Fix Keycloak URL in K8s ConfigMap to use correct NodePort 30808
CI Pipeline / Backend Build & Test (push) Successful in 57s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 34s
CI Pipeline / Infrastructure Validation (push) Successful in 4s
- Changed api-base-url from :5001 to :30501
- Changed keycloak-url from :8080 to :30808
- Changed keycloak-authority from :8080 to :30808

The frontend was trying to connect to port 8080 which is not exposed
externally. Keycloak is accessible via NodePort 30808.
2026-03-21 08:27:05 +01:00
WorkClub Automation fd2931e59c Fix Kubernetes NodePort range (30000-32767)
CI Pipeline / Backend Build & Test (push) Successful in 1m6s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 32s
CI Pipeline / Infrastructure Validation (push) Successful in 4s
- Frontend: nodePort 3000 → 30080
- Backend: nodePort 5001 → 30501, service port 5001 → 8080
- Keycloak: nodePort 8080 → 30808

Kubernetes requires NodePort to be in range 30000-32767.
The service port (internal) and targetPort (container) remain
unchanged for compatibility with existing configurations.
2026-03-20 22:50:51 +01:00
WorkClub Automation a5ebecc8b5 Remove localhost:3000 from Keycloak redirect URIs and web origins
CI Pipeline / Backend Build & Test (push) Successful in 50s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 32s
CI Pipeline / Infrastructure Validation (push) Successful in 4s
- Removed localhost:3000/* from redirectUris in realm-export.json
- Removed localhost:3000 from webOrigins in realm-export.json
- Removed localhost:3000/* from post.logout.redirect.uris
- Removed localhost:3000 from keycloak-realm-import-configmap.yaml
- Updated running Keycloak instance via kcadm.sh

Only port 30080 is now configured for OAuth redirects.
2026-03-20 22:39:15 +01:00
WorkClub Automation 956c3ead0c Fix YAML syntax error in frontend-deployment.yaml
CI Pipeline / Backend Build & Test (push) Successful in 52s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 34s
CI Pipeline / Infrastructure Validation (push) Successful in 3s
The file had malformed YAML with incorrect indentation on line 70,
causing validation to fail. Rewrote the file with correct indentation.
2026-03-20 20:50:14 +01:00
WorkClub Automation 0100def25a Align Kubernetes ports with Docker Compose configuration
CI Pipeline / Backend Build & Test (push) Successful in 58s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 43s
CI Pipeline / Infrastructure Validation (push) Failing after 4s
- Frontend: Changed NodePort from 30080 to 3000 (matches Docker port)
- Backend: Changed NodePort from 30081 to 5001 (matches Docker port)
- Keycloak: Changed NodePort from 30082 to 8080 (matches Docker port)
- Updated ConfigMap URLs to use new ports
- Updated NEXTAUTH_URL to use port 3000

This ensures Kubernetes deployment uses the same ports as Docker Compose
for consistency across environments.
2026-03-20 20:40:22 +01:00
WorkClub Automation 9cb80e4517 fix(auth): restore keycloak sign-in for NodePort access
CI Pipeline / Backend Build & Test (push) Successful in 58s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 28s
CI Pipeline / Infrastructure Validation (push) Successful in 4s
Trust external host for Auth.js, provide missing frontend auth env/secrets, and submit a proper CSRF-backed sign-in POST so browser login reaches Keycloak reliably.
2026-03-13 06:52:18 +01:00
WorkClub Automation d4f09295be feat(k8s): expose workclub services via LAN NodePorts
Expose frontend, API, and Keycloak on stable NodePorts and align app/keycloak external URLs for local-network browser access.
2026-03-13 06:33:50 +01:00
WorkClub Automation eaa163afa4 fix(k8s): stabilize keycloak rollout and align CD deploy manifests
Update Keycloak probe/realm import behavior and authority config so auth services start reliably on the dev cluster, while keeping CD deployment steps aligned with the actual Kubernetes overlay behavior.
2026-03-13 06:25:07 +01:00
WorkClub Automation 7272358746 fix(k8s): extreme probe timeouts for RPi and final Keycloak 26 admin fix
CI Pipeline / Backend Build & Test (push) Successful in 51s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 28s
CI Pipeline / Infrastructure Validation (push) Successful in 3s
2026-03-10 22:22:36 +01:00
WorkClub Automation 9b1ceb1fb4 fix(k8s): fix image names, keycloak 26 envs, and bump resource limits for RPi
CI Pipeline / Backend Build & Test (push) Successful in 52s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 42s
CI Pipeline / Infrastructure Validation (push) Successful in 5s
2026-03-10 22:16:31 +01:00
WorkClub Automation 90ae752652 fix(k8s): enable keycloak health endpoints and increase probe delays
CI Pipeline / Backend Build & Test (push) Successful in 1m2s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 29s
CI Pipeline / Infrastructure Validation (push) Successful in 3s
2026-03-10 22:07:02 +01:00
WorkClub Automation 3c41f0e40c fix(k8s): use args instead of command for keycloak to allow default entrypoint
CI Pipeline / Backend Build & Test (push) Successful in 1m19s
CI Pipeline / Frontend Lint, Test & Build (push) Successful in 26s
CI Pipeline / Infrastructure Validation (push) Successful in 4s
2026-03-10 22:02:48 +01:00
WorkClub Automation b204f6aa32 fix(k8s): register secrets and postgres-patch in dev kustomization
CI Pipeline / Frontend Lint, Test & Build (push) Has been cancelled
CI Pipeline / Infrastructure Validation (push) Has been cancelled
CI Pipeline / Backend Build & Test (push) Has been cancelled
2026-03-10 21:42:31 +01:00
WorkClub Automation 0a4d99b65b fix(k8s): add dev secrets and use emptyDir for postgres on storage-less cluster
CI Pipeline / Frontend Lint, Test & Build (push) Has been cancelled
CI Pipeline / Infrastructure Validation (push) Has been cancelled
CI Pipeline / Backend Build & Test (push) Has been cancelled
2026-03-10 21:18:19 +01:00
WorkClub Automation c5b3fbe4cb Added Kubernetes Cluster Deployment
CI Pipeline / Backend Build & Test (push) Failing after 55s
CI Pipeline / Frontend Lint, Test & Build (push) Failing after 33s
CI Pipeline / Infrastructure Validation (push) Successful in 9s
2026-03-10 19:58:55 +01:00
WorkClub Automation 326a4f30e8 infra(k8s): add dev overlay with resource limits and health checks
Implements Task 25: Kustomize Dev Overlay + Resource Limits + Health Checks

Files Created:
- infra/k8s/overlays/dev/kustomization.yaml - Dev overlay config
  - References base manifests
  - Namespace: workclub-dev
  - Replicas: 1 for all deployments
  - Image tags: dev for workclub-api and workclub-frontend
  - Environment label: development

- infra/k8s/overlays/dev/patches/backend-resources.yaml
  - Backend resources: cpu=50m-200m, memory=128Mi-256Mi
  - Strategic merge patch targeting workclub-api deployment

- infra/k8s/overlays/dev/patches/frontend-resources.yaml
  - Frontend resources: cpu=50m-200m, memory=128Mi-256Mi
  - Strategic merge patch targeting workclub-frontend deployment

- frontend/src/app/api/health/route.ts
  - Missing health endpoint (declared in base manifest but not implemented)
  - Simple Next.js route handler returning {status: 'ok'}

Resource Limits (Dev vs Base):
- Dev: 50m-200m CPU, 128Mi-256Mi memory (50% of base)
- Base: 100m-500m CPU, 256Mi-512Mi memory

Verification:
- kustomize build succeeds (exit 0)
- All deployments replicas=1
- Lower resource limits applied correctly
- Image tags set to dev
- Frontend /api/health route registered
- Evidence saved to .sisyphus/evidence/task-25-kustomize-dev.yaml (495 lines)

Note: commonLabels deprecated warning (non-blocking), consider using labels in future.
2026-03-03 21:11:18 +01:00
WorkClub Automation ba024c45be feat(domain): add core entities — Club, Member, WorkItem, Shift with state machine
- Create domain entities in WorkClub.Domain/Entities: Club, Member, WorkItem, Shift, ShiftSignup
- Implement enums: SportType, ClubRole, WorkItemStatus
- Add ITenantEntity interface for multi-tenancy support
- Implement state machine validation on WorkItem with C# 14 switch expressions
- Valid transitions: Open→Assigned→InProgress→Review→Done, Review→InProgress (rework)
- All invalid transitions throw InvalidOperationException
- TDD approach: Write tests first, 12/12 passing
- Use required properties with explicit Guid/Guid? for foreign keys
- DateTimeOffset for timestamps (timezone-aware, multi-tenant friendly)
- RowVersion byte[] for optimistic concurrency control
- No navigation properties yet (deferred to EF Core task)
- No domain events or validation attributes (YAGNI for MVP)
2026-03-03 14:09:25 +01:00