Class KubernetesClientConfiguration.ServiceAccount
java.lang.Object
io.micronaut.kubernetes.client.openapi.config.KubernetesClientConfiguration.ServiceAccount
- Enclosing class:
 - KubernetesClientConfiguration
 
@ConfigurationProperties("service-account")
public static class KubernetesClientConfiguration.ServiceAccount
extends Object
Service account authentication configuration.
- 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionPath to the certificate authority file.Path to the namespace file.Path to the token file.Token reload interval.booleanEnable/disable service account authentication.voidsetCertificateAuthorityPath(String certificateAuthorityPath) Sets path to the certificate authority file.voidsetEnabled(boolean enabled) Enable/disable service account authentication.voidsetNamespacePath(String namespacePath) Sets path to the namespace file.voidsetTokenPath(String tokenPath) Sets path to the token file.voidsetTokenReloadInterval(Duration tokenReloadInterval) Sets token reload interval. 
- 
Constructor Details
- 
ServiceAccount
public ServiceAccount() 
 - 
 - 
Method Details
- 
isEnabled
public boolean isEnabled()Enable/disable service account authentication. Default:true.- Returns:
 trueif service account authentication enabled,falseotherwise
 - 
setEnabled
public void setEnabled(boolean enabled) Enable/disable service account authentication.- Parameters:
 enabled-trueto enable service account authentication
 - 
getCertificateAuthorityPath
Path to the certificate authority file. Default:file:/var/run/secrets/kubernetes.io/serviceaccount/ca.crt.- Returns:
 - path to the certificate authority file
 
 - 
setCertificateAuthorityPath
Sets path to the certificate authority file.- Parameters:
 certificateAuthorityPath- path to the certificate authority file
 - 
getTokenPath
Path to the token file. Default:file:/var/run/secrets/kubernetes.io/serviceaccount/token.- Returns:
 - path to the token file
 
 - 
setTokenPath
Sets path to the token file.- Parameters:
 tokenPath- path to the token file
 - 
getNamespacePath
Path to the namespace file. Default:file:/var/run/secrets/kubernetes.io/serviceaccount/namespace.- Returns:
 - path to the namespace file
 
 - 
setNamespacePath
Sets path to the namespace file.- Parameters:
 namespacePath- path to the namespace file
 - 
getTokenReloadInterval
Token reload interval. Default:60s.- Returns:
 - token reload interval
 
 - 
setTokenReloadInterval
Sets token reload interval.- Parameters:
 tokenReloadInterval- token reload interval
 
 -