- GCP account
- Install locally
- gcloud SDK
- kubectl
- helm
-
Create GCP project.
-
Create service account for terraform.
- Make sure that account has an Owner permissions for containers
- Make sure that account has an Editor permissions for buckets, GKE, LB, etc...
-
Initialize gcloud for your GCP project
-
Create Bucket to store Terrform state
gsutil mb gs://dark-garden-256113-tfstate
gsutil versioning set on gs://dark-garden-256113-tfstate
-
Clone Vault Helm charts (for Vault installation only)
git clone https://github.com/hashicorp/vault-helm.git ../vault-helm
-
Run Terrform
- Pass variables: account config file, bucket for Kubernetes, project name
terraform init
terraform plan
terraform apply
- Pass variables: account config file, bucket for Kubernetes, project name
They are installed by local exec in terraform because modules do not work with Helm3.
Commands examples were used for Vault and Prometheus installation
helm --kubeconfig=modules/gke/kubeconfig install vault ../vault-helm
helm --kubeconfig=modules/gke/kubeconfig install -f modules/helm/monitoring/prometheus/values.yml prometheus stable/prometheus-operator