(kubernetes-clouds-and-juju)= # Kubernetes clouds and Juju In Juju, all Kubernetes clouds behave fundamentally the same. ## Notes on `juju add-k8s` On Kubernetes clouds, both the cloud definition and the cloud credentials are added through `juju add-k8s`, which reads from your kubeconfig file. ### Authentication types #### `certificate` Attributes: - ClientCertificateData: the kubernetes certificate data (required) - Token: the kubernetes service account bearer token (required) - rbac-id: the unique ID key name of the rbac resources (optional) #### `clientcertificate` Attributes: - ClientCertificateData: the kubernetes certificate data (required) - ClientKeyData: the kubernetes certificate key (required) - rbac-id: the unique ID key name of the rbac resources (optional) #### `oauth2` Attributes: - Token: the kubernetes token (required) - rbac-id: the unique ID key name of the rbac resources (optional) #### `oauth2withcert` Attributes: - ClientCertificateData: the kubernetes certificate data (required) - ClientKeyData: the kubernetes private key data (required) - Token: the kubernetes token (required) #### `userpass` Attributes: - username: The username to authenticate with. (required) - password: The password for the specified username. (required) ## Cloud-specific model configuration keys ### `operator-storage` The storage class used to provision operator storage. | | | |-|-| | type | string | | default value | "" | | immutable | true | | mandatory | false | ### `workload-storage` The preferred storage class used to provision workload storage. | | | |-|-| | type | string | | default value | "" | | immutable | false | | mandatory | false | ## Supported constraints | {ref}`CONSTRAINT ` | | |----------------------------------------|-----------------------------------------------| | conflicting: | `instance-type` vs. `[cores, cpu-power, mem]` | | supported? | | | - {ref}`constraint-allocate-public-ip` | ✕ | | - {ref}`constraint-arch` | ✕ | | - {ref}`constraint-container` | ✕ | | - {ref}`constraint-cores` | ✕ | | - {ref}`constraint-cpu-power` | ✓ | | - {ref}`constraint-image-id` | ✕ | | - {ref}`constraint-instance-role` | ✕ | | - {ref}`constraint-instance-type` | ✕ | | - {ref}`constraint-mem` | ✓ | | - {ref}`constraint-root-disk` | ✕ | | - {ref}`constraint-root-disk-source` | ✕ | | - {ref}`constraint-spaces` | ✕ | | - {ref}`constraint-tags` | ✓
Used for affinity. | | - {ref}`constraint-virt-type` | ✕ | | - {ref}`constraint-zones` | ✕ | ## Placement directives Placement directives aren't supported on Kubernetes clouds.