Skip to content

ClusterImageSetMirror does not work with private repos #606

Description

@ttruong-actian

here are my setup

apiVersion: kuik.enix.io/v1alpha1
kind: ClusterImageSetMirror
metadata:
  annotations:
    argocd.argoproj.io/sync-wave: "10"
    argocd.argoproj.io/tracking-id: tools-dev-kube-image-keeper-v2:kuik.enix.io/ClusterImageSetMirror:kuik-system/kuik-global-mirror
  creationTimestamp: "2026-06-05T17:37:37Z"
  finalizers:
  - kuik.enix.io/secret-cleanup
  - kuik.enix.io/mirror-cleanup
  generation: 5
  name: kuik-global-mirror
  resourceVersion: "1130033109"
  uid: c8cacd2a-bf23-4404-b1b7-5f57c629225a
spec:
  cleanup:
    enabled: false
    retention: 168h0m0s
  imageFilter:
    exclude:
    - ^localhost[^/]+/.+
    - ^[0-9]{12}\.dkr\.ecr\.[^.]+\.amazonaws\.com/.+
    - ^docker\.io/goharbor/.+
    - ^quay\.io/apicurio/apicurio-registry-3-operator.+
    include:
    - .*
  mirrors:
  - credentialSecret:
      name: ecr-push-creds
      namespace: kuik-system
    path: /kuik-cache
    registry: <awsAccountId>.dkr.ecr.us-east-2.amazonaws.com
  priority: -1

I've also ClusterReplicatedImageSet

apiVersion: kuik.enix.io/v1alpha1
kind: ClusterReplicatedImageSet
metadata:
  annotations:
    argocd.argoproj.io/sync-wave: "10"
    argocd.argoproj.io/tracking-id: tools-dev-kube-image-keeper-v2:kuik.enix.io/ClusterReplicatedImageSet:kuik-system/dockerhub
  creationTimestamp: "2026-06-06T18:06:01Z"
  finalizers:
  - kuik.enix.io/secret-cleanup
  generation: 2
  name: dockerhub
  resourceVersion: "1130019302"
  uid: ad8d3a17-398a-46a1-ac29-563d220d810f
spec:
  upstreams:
  - credentialSecret:
      name: dockerhub-image-pull
      namespace: kuik-system
    imageFilter:
      include:
      - ^/.+
    path: /
    registry: docker.io

and my pods are also have the imagePullSecrets set, the pod are running just fine, just KUIK can't cache the image

all return with UNAUTHORIZED from docker.io

{"level":"error","ts":"2026-06-06T18:27:42Z","msg":"could not mirror image","controller":"kuik-clusterimagesetmirror","controllerGroup":"kuik.enix.io","controllerKind":"ClusterImageSetMirror","ClusterImageSetMirror":{"name":"kuik-global-mirror"},"namespace":"","name":"kuik-global-mirror","reconcileID":"88c8dcdd-8ee1-4813-a7a4-acdb6eefd6e3","from":"docker.io/actian/cloudops-utils:1.0.13","to":"135371550061.dkr.ecr.us-east-2.amazonaws.com/kuik-cache/actian/cloudops-utils:1.0.13","error":"GET https://index.docker.io/v2/actian/cloudops-utils/manifests/1.0.13: UNAUTHORIZED: authentication required; [map[Action:pull Class: Name:actian/cloudops-utils Type:repository]]"}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions