Install helm package on GKE cluster creation

Viewed 30

I am working on a toy project and want to connect my GitLab to my GKE. There is a one liner that does it. After creating the GKE, I can run the oneliner and it works fine.

But I don't want to keep the cluster running for long since I don't want to be charged. When I am developing, I want to deploy my infrastructure and with my infrastructure, I want my gitlab connection also setup. And after I stop it, I will run terraform destroy to stop my cluster

I am using terraform to deploy GKE, but I can't find a way to run a command inside the cluster with the deployment of my infrastructure. Is there a way to do this?

Thanks for you help

1 Answers

Please tell me if this works for you:

helm repo add stable https://kubernetes-charts.storage.googleapis.com/
helm repo add stable https://charts.helm.sh/stable
helm repo update
helm install nginx-ingress stable/nginx-ingress

kubectl apply --validate=false -f https://github.com/jetstack/cert-manager/releases/download/v0.16.0/cert-manager.yaml
Related