Helm bake should substitute ImagePullSecrets for private registries
kubernetes v2
I am running spinnaker version 1.9.0 Kubernetes on GKE
I created a helm chart that generates ImagePullSecrets (see https://github.com/helm/helm/blob/master/docs/charts_tips_and_tricks.md#creating-image-pull-secrets). The generated ImagePullSecret is created with a version, however, the image pull secret is not updated in the generated template and pod deploy fails because the image cannot be pulled for the private registry
Create a Helm chart and add ImagePullSecrets support following https://github.com/helm/helm/blob/master/docs/charts_tips_and_tricks.md#creating-image-pull-secrets)
Created secret is named secret release-registrykey-v000, generated deployment has release-registrykey
You need to tell Spinnaker not to version the configuration:
apiVersion: v1
kind: Secret
metadata:
name: myregistrykey
annotations:
'strategy.spinnaker.io/versioned': 'false' # <-- this is the important part
type: kubernetes.io/dockerconfigjson
data:
.dockerconfigjson: {{ template "imagePullSecret" . }}
https://www.spinnaker.io/reference/providers/kubernetes-v2/#strategy
Closing since I verified it works, thank you!
how can we set 'strategy.spinnaker.io/versioned': 'false' with Halyard?
Most helpful comment
You need to tell Spinnaker not to version the configuration:
https://www.spinnaker.io/reference/providers/kubernetes-v2/#strategy