The below script iterates through all the helm
charts available in the stable
and incubator
repos.
It installs, runs any registered tests and deletes the deployment.
install-test-delete () {
name=$(echo $1 | tr '/' '-')
helm install $1 --name $name --namespace helm-testing --wait --timeout 60
helm test $name --timeout 60
helm delete --purge $name --timeout 60
}
repo () {
[[ ! -z "$2" ]] && helm repo add $1 $2
for i in `helm search $1 | awk 'FNR>1 {print $1}'`; do
echo "Install Test Delete Helm Chart $i"
install-test-delete $i
done
}
repo stable
repo incubator https://kubernetes-charts-incubator.storage.googleapis.com/