Skip to content

Instantly share code, notes, and snippets.

@carlosribas
Last active March 19, 2021 19:44
Show Gist options
  • Save carlosribas/15bd2fa4b25df19704ace354a4321a8c to your computer and use it in GitHub Desktop.
Save carlosribas/15bd2fa4b25df19704ace354a4321a8c to your computer and use it in GitHub Desktop.
Change the default stable repository
# <configuration-directory>/playbooks/roles/start-helm/tasks/main.yml
---
- name: start helm
command: helm init --stable-repo-url https://charts.helm.sh/stable
- name: "get tiller-deploy pod name"
shell: >
kubectl get pods --namespace=kube-system |
grep tiller-deploy- |
awk '{print $1;}' |
tr -d '\n'
register: get_pod_name
- name: "wait for tiller-deploy ready status"
command: >
kubectl get pods --namespace=kube-system {{get_pod_name.stdout}}
-o jsonpath='{.status.containerStatuses[*].ready}'
register: tiller_ready_status
# Wait for 10 minutes
until: tiller_ready_status.stdout | match( '^(true\s)*true$' )
retries: 120
delay: 5
- name: "add KubeNow Helm repository"
command: helm repo add kubenow https://kubenow.github.io/helm-charts/
@carlosribas
Copy link
Author

Helm versions prior to 2.17.0 have the deprecated https://kubernetes-charts.storage.googleapis.com/index.yaml as the default stable repository, which no longer resolves.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment