diff --git a/helm/kc-cron-job/templates/cron-event-logs.yaml b/helm/kc-cron-job/templates/cron-event-logs.yaml index a09bb960..ee203a81 100644 --- a/helm/kc-cron-job/templates/cron-event-logs.yaml +++ b/helm/kc-cron-job/templates/cron-event-logs.yaml @@ -1,8 +1,9 @@ +{{- range .Values.namespace.eventLogs }} apiVersion: batch/v1 kind: CronJob metadata: name: {{ include "..fullname" . }}-event-logs - namespace: {{ .Values.namespace.eventLogs }} + namespace: {{ . }} labels: app.kubernetes.io/name: {{ include "..name" . }} app.kubernetes.io/instance: {{ .Release.Name }} @@ -90,3 +91,4 @@ spec: persistentVolumeClaim: claimName: {{ .Values.pvc.name }} restartPolicy: Never +{{- end }} diff --git a/helm/kc-cron-job/templates/cron-remove-inactive-users.yaml b/helm/kc-cron-job/templates/cron-remove-inactive-users.yaml index 3a69aafe..a95d32a9 100644 --- a/helm/kc-cron-job/templates/cron-remove-inactive-users.yaml +++ b/helm/kc-cron-job/templates/cron-remove-inactive-users.yaml @@ -1,3 +1,4 @@ +{{- if .Values.enableRemoveInactiveUsersJob }} apiVersion: batch/v1 kind: CronJob metadata: @@ -159,3 +160,4 @@ spec: name: kc-cron-rm-inactive-users key: rc-webhook restartPolicy: Never +{{- end }} diff --git a/helm/kc-cron-job/values-c6af30-tools.yaml b/helm/kc-cron-job/values-c6af30-tools.yaml index 0e2b5eee..927c2f77 100644 --- a/helm/kc-cron-job/values-c6af30-tools.yaml +++ b/helm/kc-cron-job/values-c6af30-tools.yaml @@ -9,9 +9,15 @@ imagePullSecrets: nameOverride: kc-cron-job fullnameOverride: kc-cron-job +enableRemoveInactiveUsersJob: false + namespace: - eventLogs: 'c6af30-prod' + eventLogs: + - 'c6af30-dev' + - 'c6af30-test' + - 'c6af30-prod' activeSessions: 'c6af30-tools' + rmInactiveUsers: 'c6af30-tools' pvc: name: sso-keycloak-logs diff --git a/helm/kc-cron-job/values-eb75ad-tools.yaml b/helm/kc-cron-job/values-eb75ad-tools.yaml index d3dc0185..b2cb7f0a 100644 --- a/helm/kc-cron-job/values-eb75ad-tools.yaml +++ b/helm/kc-cron-job/values-eb75ad-tools.yaml @@ -9,8 +9,13 @@ imagePullSecrets: nameOverride: kc-cron-job fullnameOverride: kc-cron-job +enableRemoveInactiveUsersJob: false + namespace: - eventLogs: 'eb75ad-prod' + eventLogs: + - 'eb75ad-dev' + - 'eb75ad-test' + - 'eb75ad-prod' activeSessions: 'eb75ad-tools' rmInactiveUsers: 'eb75ad-tools' diff --git a/localdev/macs/docker-compose-kc-legacy.yml b/localdev/macs/docker-compose-kc-legacy.yml new file mode 100644 index 00000000..2cdc779a --- /dev/null +++ b/localdev/macs/docker-compose-kc-legacy.yml @@ -0,0 +1,39 @@ +version: '3.8' + +services: + keycloak: + container_name: keycloak + image: keycloak:9.0.3 + depends_on: + - postgres + ports: + - 8080:8080 + environment: + DB_VENDOR: POSTGRES + DB_PORT: 5432 + DB_USER: keycloak + DB_PASSWORD: keycloak + DB_ADDR: postgres:5432 + DB_DATABASE: keycloak + KEYCLOAK_USER: admin + KEYCLOAK_PASSWORD: admin + KEYCLOAK_LOGLEVEL: INFO + ROOT_LOGLEVEL: INFO + + postgres: + image: postgres:13 + container_name: postgres + environment: + POSTGRES_DB: keycloak + POSTGRES_USER: keycloak + POSTGRES_PASSWORD: keycloak + restart: on-failure + tty: true + ports: + - 5432:5432 + volumes: + - postgres_data:/var/lib/postgresql/data + +volumes: + postgres_data: + driver: local