how to set `imagePullPolicy` for container image `keycloak:26.0.5`

Hey, could you advise on how to set the imagePullPolicy for keycloak:26.0.5, similar to how it’s already configured for keycloak-operator:26.0.5?

Currently, the relevant configuration looks like this:

spec:
  containers:
    - env:
        - name: KUBERNETES_NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.namespace
        - name: RELATED_IMAGE_KEYCLOAK
          value: keycloak:26.0.5
      image: keycloak-operator:26.0.5 
      imagePullPolicy: Never

I attempted the following but was unsuccessful:

unsupported:
  podTemplate:
    spec:
      containers:
        - imagePullPolicy: Never

Would appreciate any insights on the correct approach.

Hello @nskalis , you’re question is related to Kubernetes knowledges, not to Keycloak. You should consider learning more about Kubernetes and the concept of Kubernetes operators and custom resources before going further.

If I am mistaken it and you already have good knowledge of Kubernetes, you should review your question because it doesn’t make sense to me.

1 Like

For those seeking a constructive comment, the original question was indeed correct—I had a typo in the rest of the configuration.

No, the original quesion is not correct :

This part of the question just demonstrate that you don’t understand the concept of imagePullPolicy in kubernetes context. It is not specific to keycloak. A correct question would have been “how to set the imagePullPolicy ?”. And I would answer that with the same answer I made above.

1 Like