diff --git a/infrastructure/controllers/keycloak-operator/README.md b/infrastructure/controllers/keycloak-operator/README.md index 1ef2c2f..c08c4ad 100644 --- a/infrastructure/controllers/keycloak-operator/README.md +++ b/infrastructure/controllers/keycloak-operator/README.md @@ -14,6 +14,11 @@ Kubernetes 리소스를 직접 참조하며 업스트림 매니페스트를 복 - 저장소: - 리소스 경로: `kubernetes` - Keycloak 및 Operator 버전: `26.7.0` +- 원격 ref: 태그가 아니라 그 태그의 커밋 `38fd7a0c84e15d4b66b37d1c2ea728ca2f5416a4`(2026-11-12). 같은 태그의 내용이 + 한 번 바뀌었다(build-timestamp 07-09 → 07-23, 성숙도 점검 A5). +- 이미지: Operator·Keycloak 모두 2026-11-12에 돌던 digest로 고정, Operator `imagePullPolicy: IfNotPresent`. + Keycloak CR의 `spec.image`를 정하면 Operator가 최적화 빌드된 이미지로 보므로 `startOptimized: false`를 같이 둔다. + 올릴 때는 태그·커밋·두 digest와 `scripts/validate/render-phase2.sh`·`scripts/bootstrap/apply-keycloak.sh`의 검사 문자열을 함께 바꾼다. - 설치 모드: `keycloak` namespace 범위 업스트림 namespace 범위 Deployment는 각 컨트롤러의 감시 namespace를 diff --git a/infrastructure/controllers/keycloak-operator/kustomization.yaml b/infrastructure/controllers/keycloak-operator/kustomization.yaml index d8c89fc..4c8fce9 100644 --- a/infrastructure/controllers/keycloak-operator/kustomization.yaml +++ b/infrastructure/controllers/keycloak-operator/kustomization.yaml @@ -3,8 +3,38 @@ kind: Kustomization namespace: keycloak +# keycloak-k8s-resources tag 26.7.0 pointed at this commit on 2026-11-12. The tag +# content changed once (live build-timestamp 2026-07-09, later renders 2026-07-23), +# so the commit is pinned instead of the tag. resources: - - github.com/keycloak/keycloak-k8s-resources/kubernetes?ref=26.7.0 + - github.com/keycloak/keycloak-k8s-resources/kubernetes?ref=38fd7a0c84e15d4b66b37d1c2ea728ca2f5416a4 + +# The 26.7.0 images that were running on 2026-11-12 (pod imageID), by digest. +images: + - name: quay.io/keycloak/keycloak-operator + digest: sha256:257ee324da2c701b7fc1ed1b2ce0e03979d1bf149952383bdcf6be904ae5b4f3 + +patches: + # Merged by container and env name (strategic merge), not by list index. + - target: + group: apps + version: v1 + kind: Deployment + name: keycloak-operator + patch: |- + apiVersion: apps/v1 + kind: Deployment + metadata: + name: keycloak-operator + spec: + template: + spec: + containers: + - name: keycloak-operator + imagePullPolicy: IfNotPresent + env: + - name: RELATED_IMAGE_KEYCLOAK + value: quay.io/keycloak/keycloak@sha256:0f198be292568439d700cdbfb893e69a6009bb43a94a06a945b1d3d506c76b13 labels: - pairs: diff --git a/scripts/bootstrap/apply-keycloak.sh b/scripts/bootstrap/apply-keycloak.sh index aa17f67..ca2558e 100755 --- a/scripts/bootstrap/apply-keycloak.sh +++ b/scripts/bootstrap/apply-keycloak.sh @@ -189,8 +189,8 @@ assert_regex_count \ assert_regex_count \ "${REPOSITORY_ROOT}/infrastructure/controllers/keycloak-operator/kustomization.yaml" \ - 'github\.com/keycloak/keycloak-k8s-resources/kubernetes\?ref=26\.7\.0' 1 \ - "Keycloak Operator 26.7.0 source pin" + 'github\.com/keycloak/keycloak-k8s-resources/kubernetes\?ref=38fd7a0c84e15d4b66b37d1c2ea728ca2f5416a4' 1 \ + "Keycloak Operator 26.7.0 commit pin" assert_regex_count \ "${render_temp_dir}/keycloak-operator.yaml" \ '^kind:[[:space:]]CustomResourceDefinition$' 4 \ diff --git a/scripts/validate/render-phase2.sh b/scripts/validate/render-phase2.sh index a214de2..2190de8 100755 --- a/scripts/validate/render-phase2.sh +++ b/scripts/validate/render-phase2.sh @@ -266,7 +266,8 @@ aistor_objectstore_kustomization="${REPOSITORY_ROOT}/services/minio-aistor/base/ aistor_operator_values="${REPOSITORY_ROOT}/infrastructure/controllers/aistor-operator/values/home.yaml" aistor_objectstore_values="${REPOSITORY_ROOT}/services/minio-aistor/base/deployment/values/home.yaml" -assert_regex_count "$keycloak_operator_kustomization" '^[[:space:]]*-[[:space:]]github\.com/keycloak/keycloak-k8s-resources/kubernetes\?ref=26\.7\.0[[:space:]]*$' 1 "Keycloak Operator remote ref must be 26.7.0" +assert_regex_count "$keycloak_operator_kustomization" '^[[:space:]]*-[[:space:]]github\.com/keycloak/keycloak-k8s-resources/kubernetes\?ref=38fd7a0c84e15d4b66b37d1c2ea728ca2f5416a4[[:space:]]*$' 1 "Keycloak Operator remote ref must be the 26.7.0 commit" +assert_regex_count "$keycloak_operator_kustomization" '^[[:space:]]*digest:[[:space:]]sha256:257ee324da2c701b7fc1ed1b2ce0e03979d1bf149952383bdcf6be904ae5b4f3[[:space:]]*$' 1 "Keycloak Operator image must be pinned by digest" assert_regex_count "$keycloak_operator_kustomization" 'github\.com/keycloak/keycloak-k8s-resources/kubernetes' 1 "exactly one Keycloak Operator remote resource is allowed" assert_regex_count "$keycloak_operator_kustomization" '\?ref=' 1 "exactly one pinned remote ref is allowed in the Keycloak Operator root"