kubernetes_namespace

Kubernetes supports multiple virtual clusters backed by the same physical cluster. These virtual clusters are called namespaces. Read more about namespaces at https://kubernetes.io/docs/user-guide/namespaces/

Example Usage

resource "kubernetes_namespace" "example" {
  metadata {
    annotations {
      name = "example-annotation"
    }

    labels {
      mylabel = "label-value"
    }

    name = "terraform-example-namespace"
  }
}

Argument Reference

The following arguments are supported:

Nested Blocks

metadata

Arguments

Attributes

Import

Namespaces can be imported using their name, e.g.

$ terraform import kubernetes_namespace.n terraform-example-namespace

© 2018 HashiCorp
Licensed under the MPL 2.0 License.
https://www.terraform.io/docs/providers/kubernetes/r/namespace.html