Class KubeConfigWriter
- java.lang.Object
-
- org.jenkinsci.plugins.kubernetes.cli.kubeconfig.KubeConfigWriter
-
public class KubeConfigWriter extends Object
- Author:
- Max Laverse
-
-
Field Summary
Fields Modifier and Type Field Description static String
ENV_VARIABLE_NAME
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description io.fabric8.kubernetes.api.model.ConfigBuilder
getConfigBuilderInCluster()
io.fabric8.kubernetes.api.model.ConfigBuilder
getConfigBuilderWithAuth(String credentialsId, org.jenkinsci.plugins.kubernetes.auth.KubernetesAuth auth)
String
writeKubeConfig()
Write a configuration file for kubectl to disk.
-
-
-
Field Detail
-
ENV_VARIABLE_NAME
public static final String ENV_VARIABLE_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
writeKubeConfig
public String writeKubeConfig() throws IOException, InterruptedException
Write a configuration file for kubectl to disk.- Returns:
- path to kubeconfig file
- Throws:
IOException
- on file operationsInterruptedException
- on file operations
-
getConfigBuilderInCluster
public io.fabric8.kubernetes.api.model.ConfigBuilder getConfigBuilderInCluster() throws IOException, InterruptedException
- Throws:
IOException
InterruptedException
-
getConfigBuilderWithAuth
public io.fabric8.kubernetes.api.model.ConfigBuilder getConfigBuilderWithAuth(String credentialsId, org.jenkinsci.plugins.kubernetes.auth.KubernetesAuth auth) throws IOException, InterruptedException
- Throws:
IOException
InterruptedException
-
-