public class Environments extends Object
Modifier and Type | Field and Description |
---|---|
static String |
ENVIRONMENTS_CONFIGMAP_NAME |
static String |
SPACE_LINK_CONFIGMAP_NAME |
Constructor and Description |
---|
Environments(String namespace,
Map<String,Environment> environments) |
Modifier and Type | Method and Description |
---|---|
static String |
findSpaceNamespace(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient)
Tries to find the current space namespace from the current namespace
|
static String |
findSpaceNamespace(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient,
String namespace)
Tries to find the current space namespace from the current namespace
|
protected static String |
getDefaultNamespace(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient,
String namespace) |
Environment |
getEnvironment(String environmentKey) |
Map<String,Environment> |
getEnvironments() |
SortedSet<Environment> |
getEnvironmentSet()
Returns the sorted set of environments
|
String |
getNamespace()
Returns the main namespace that contains the
ENVIRONMENTS_CONFIGMAP_NAME ConfigMap that points
to all the other environments |
static Environments |
load() |
static Environments |
load(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient,
String namespace) |
static Environments |
load(String namespace) |
static String |
namespaceForEnvironment(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient,
String environmentKey,
String namespace)
Returns the namespace for the given environment name if its defined or null if one cannot be found
|
static String |
namespaceForEnvironment(String environmentKey)
Returns the namespace for the given environment name
|
static String |
namespaceForEnvironment(String environmentKey,
String namespace)
Returns the namespace for the given environment name if its defined or null if one cannot be found
|
public static final String ENVIRONMENTS_CONFIGMAP_NAME
public static final String SPACE_LINK_CONFIGMAP_NAME
public Environments(String namespace, Map<String,Environment> environments)
public static Environments load()
public static Environments load(String namespace)
public static Environments load(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient, String namespace)
public static String findSpaceNamespace(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient)
public static String findSpaceNamespace(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient, String namespace)
public static String namespaceForEnvironment(String environmentKey)
public static String namespaceForEnvironment(String environmentKey, String namespace)
public static String namespaceForEnvironment(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient, String environmentKey, String namespace)
protected static String getDefaultNamespace(io.fabric8.kubernetes.client.KubernetesClient kubernetesClient, String namespace)
public String getNamespace()
ENVIRONMENTS_CONFIGMAP_NAME
ConfigMap that points
to all the other environmentspublic Environment getEnvironment(String environmentKey)
public Map<String,Environment> getEnvironments()
public SortedSet<Environment> getEnvironmentSet()
Copyright © 2011–2017 Red Hat. All rights reserved.