Documentation
¶
Index ¶
Constants ¶
View Source
const ( // DefaultNamespace is the namespace the cluster-admin-email secret lives in. DefaultNamespace = "codesphere" // DefaultSecretName is the name of the secret holding the cluster admin email. // It is referenced by the platform deployment via a secretKeyRef. DefaultSecretName = "cluster-admin-email" // EmailKey is the secret data key under which the admin email is stored. EmailKey = "email" )
Variables ¶
This section is empty.
Functions ¶
func AddClusterAdmin ¶
AddClusterAdmin writes the given email to the cluster-admin-email secret in the target cluster, creating the secret if it does not exist yet or updating it otherwise.
The email is stored under the EmailKey data key. Running the command again with a different email overwrites the previous value.
func NormalizeEmail ¶ added in v1.227.0
NormalizeEmail validates and canonicalizes an email address.
Types ¶
type Opts ¶
type Opts struct {
Email string
Namespace string
SecretName string
// CreateNamespace creates the target namespace if it does not exist yet
// instead of failing. Used during installation, where the secret may be
// written before the platform charts have created the namespace.
CreateNamespace bool
}
Opts contains the options for adding a cluster admin.
Click to show internal directories.
Click to hide internal directories.