Difference between revisions of "Kubernetes service account v1"
Jump to navigation
Jump to search
(Created page with "{{lc}} resource "kubernetes_service_account_v1" "service_account" { depends_on = [kubernetes_namespace_v1.namespace, module.gcp] count = var.service_account_name !=...") |
|||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
{{lc}} | {{lc}} | ||
+ | See: https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/service_account_v1 | ||
+ | |||
+ | https://github.com/djangoflow/terraform-kubernetes-django/blob/main/service_account.tf | ||
resource "kubernetes_service_account_v1" "service_account" { | resource "kubernetes_service_account_v1" "service_account" { | ||
depends_on = [kubernetes_namespace_v1.namespace, module.gcp] | depends_on = [kubernetes_namespace_v1.namespace, module.gcp] | ||
Line 13: | Line 16: | ||
automount_service_account_token = false | automount_service_account_token = false | ||
} | } | ||
+ | |||
+ | |||
+ | |||
+ | {{tf k8s}} |
Latest revision as of 11:59, 8 March 2024
https://github.com/djangoflow/terraform-kubernetes-django/blob/main/service_account.tf
resource "kubernetes_service_account_v1" "service_account" { depends_on = [kubernetes_namespace_v1.namespace, module.gcp] count = var.service_account_name != null ? 1 : 0 metadata { name = var.service_account_name namespace = var.namespace labels = local.common_labels annotations = { "iam.gke.io/gcp-service-account" = length(module.gcp) > 0 ? module.gcp.0.sa_email : null } } automount_service_account_token = false }
Terraform provider: Kubernetes, kubernetes_storage_class_v1, kubernetes_persistent_volume, kubernetes_manifest, kubernetes daemonset, kubernetes_service, kubernetes_namespace, kubernetes_service_account, kubernetes_secret, kubernetes_namespace, kubernetes_service_account_v1, kubernetes_secret_v1, kubernetes horizontal pod autoscaler v1, kubernetes_ingress_v1, kubernetes_persistent_volume_claim_v1
Advertising: