1.8. Configuring ImagePullPolicy


The GitOps Operator lets administrators configure imagePullPolicy at multiple levels to control how Argo CD components pull container images.

The imagePullPolicy configuration follows a hierarchical precedence system, where the most specific configuration takes priority:

  • Instance-level policy - Defined in the Argo CD CR by using the spec.imagePullPolicy field.
  • Global-level policy - Defined through the IMAGE_PULL_POLICY environment variable in the GitOps Operators Subscription.
  • Default policy - IfNotPresent is used when neither of the earlier configurations are specified.
ValueDescription

Always

Always pull the image.

IfNotPresent

Pull the image only if it is not present locally.

Never

Never pull the image.

You can define a global image pull policy for all Argo CD instances managed by the Operator by setting the IMAGE_PULL_POLICY environment variable in the Operator’s Subscription. For example:

apiVersion: operators.coreos.com/v1alpha1
kind: Subscription
metadata:
  name: openshift-gitops-operator
spec:
  config:
    env:
      - name: IMAGE_PULL_POLICY
        value: "Always"

An instance-level configuration overrides the Operator-level policy and applies the configuration only to the specific instance defined in the CR.

The following example shows how to configure imagePullPolicy for all the components in an Argo CD instance.

apiVersion: argoproj.io/v1beta1
kind: ArgoCD
metadata:
  name: argocd
  namespace: argocd
spec:
  imagePullPolicy: IfNotPresent

The following example shows how to define imagePullPolicy for all the components in a GitOpsService instance.

apiVersion: pipelines.openshift.io/v1alpha1
kind: GitOpsService
metadata:
  name: gitops-service
  namespace: openshift-gitops
spec:
  imagePullPolicy: Always

The following example shows how to set imagePullPolicy for all the components in a RolloutsManager instance.

apiVersion: argoproj.io/v1alpha1
kind: RolloutManager
metadata:
  name: argo-rollout
  labels:
    example: basic
spec:
  imagePullPolicy: Always

By configuring the imagePullPolicy at an appropriate level, you can control how often container images are updated for your GitOps components.

Red Hat logoGithubRedditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 문서 정보

Legal Notice

Theme

© 2026 Red Hat
맨 위로 이동