Skip to main content

GetNamespaceName

Returns a Kubernetes namespace name by replacing placeholders in a user-defined template with provided organization, project, and domain values.

def GetNamespaceName(
template: string,
org: string,
project: string,
domain: string
) - > string

Returns a Kubernetes namespace name by replacing placeholders in a user-defined template with provided organization, project, and domain values. This function is used to dynamically generate namespace names based on configuration.

Parameters

NameTypeDescription
templatestringThe template string containing placeholders for organization, project, and domain that will be replaced to form the namespace name.
orgstringThe organization name to be used for replacing the organization placeholder in the template.
projectstringThe project name to be used for replacing the project placeholder in the template.
domainstringThe domain name to be used for replacing the domain placeholder in the template.

Returns

TypeDescription
stringThe formatted Kubernetes namespace name with placeholders replaced.