diff --git a/infra/k8s/base/frontend-deployment.yaml b/infra/k8s/base/frontend-deployment.yaml index 92e5df0..ee8c1bd 100644 --- a/infra/k8s/base/frontend-deployment.yaml +++ b/infra/k8s/base/frontend-deployment.yaml @@ -40,7 +40,6 @@ spec: periodSeconds: 15 timeoutSeconds: 5 failureThreshold: 3 - resources: requests: cpu: 100m @@ -48,7 +47,6 @@ spec: limits: cpu: 500m memory: 512Mi - env: - name: NODE_ENV value: "production" @@ -67,8 +65,8 @@ spec: configMapKeyRef: name: workclub-config key: keycloak-authority - - name: NEXTAUTH_URL - value: "http://192.168.240.200:3000" + - name: NEXTAUTH_URL + value: "http://192.168.240.200:3000" - name: AUTH_TRUST_HOST value: "true" - name: NEXTAUTH_SECRET diff --git a/infra/k8s/base/frontend-deployment.yaml.bak b/infra/k8s/base/frontend-deployment.yaml.bak new file mode 100644 index 0000000..92e5df0 --- /dev/null +++ b/infra/k8s/base/frontend-deployment.yaml.bak @@ -0,0 +1,92 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: workclub-frontend + labels: + app: workclub-frontend + component: frontend +spec: + replicas: 1 + selector: + matchLabels: + app: workclub-frontend + template: + metadata: + labels: + app: workclub-frontend + component: frontend + spec: + containers: + - name: frontend + image: 192.168.241.13:8080/workclub-frontend:latest + imagePullPolicy: IfNotPresent + ports: + - name: http + containerPort: 3000 + protocol: TCP + readinessProbe: + httpGet: + path: /api/health + port: http + initialDelaySeconds: 5 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 2 + livenessProbe: + httpGet: + path: /api/health + port: http + initialDelaySeconds: 10 + periodSeconds: 15 + timeoutSeconds: 5 + failureThreshold: 3 + + resources: + requests: + cpu: 100m + memory: 256Mi + limits: + cpu: 500m + memory: 512Mi + + env: + - name: NODE_ENV + value: "production" + - name: NEXT_PUBLIC_API_URL + valueFrom: + configMapKeyRef: + name: workclub-config + key: api-base-url + - name: NEXT_PUBLIC_KEYCLOAK_URL + valueFrom: + configMapKeyRef: + name: workclub-config + key: keycloak-url + - name: NEXT_PUBLIC_KEYCLOAK_ISSUER + valueFrom: + configMapKeyRef: + name: workclub-config + key: keycloak-authority + - name: NEXTAUTH_URL + value: "http://192.168.240.200:3000" + - name: AUTH_TRUST_HOST + value: "true" + - name: NEXTAUTH_SECRET + valueFrom: + secretKeyRef: + name: workclub-secrets + key: nextauth-secret + - name: KEYCLOAK_CLIENT_ID + value: "workclub-app" + - name: KEYCLOAK_CLIENT_SECRET + valueFrom: + secretKeyRef: + name: workclub-secrets + key: keycloak-client-secret + - name: KEYCLOAK_ISSUER + valueFrom: + configMapKeyRef: + name: workclub-config + key: keycloak-authority + - name: KEYCLOAK_ISSUER_INTERNAL + value: "http://workclub-keycloak/realms/workclub"