apiVersion: apps.openshift.io/v1
kind: DeploymentConfig
metadata:
  name: keycloak
spec:
  replicas: 1
  selector:
    deploymentConfig: keycloak
  strategy:
    type: Recreate
  template:
    metadata:
      labels:
        application: keycloak
        deploymentConfig: keycloak
      name: keycloak
    spec:
      containers:
        - envFrom:
            - secretRef:
                name: janus-idp
          image: quay.io/keycloak/keycloak:20.0.3
          livenessProbe:
            failureThreshold: 100
            httpGet:
              path: /
              port: 8080
              scheme: HTTP
            initialDelaySeconds: 60
          name: keycloak
          ports:
            - containerPort: 8080
              protocol: TCP
          readinessProbe:
            failureThreshold: 300
            httpGet:
              path: /
              port: 8080
              scheme: HTTP
            initialDelaySeconds: 30
          securityContext:
            privileged: false
          volumeMounts:
            - mountPath: /opt/keycloak/data
              name: empty
          args: ["start-dev"]
      volumes:
        - name: empty
          emptyDir: {}
  triggers:
    - type: ConfigChange
