pub enum KubeconfigError {
Show 16 variants
CurrentContextNotSet,
KindMismatch,
ApiVersionMismatch,
LoadContext(String),
LoadClusterOfContext(String),
FindPath,
ReadConfig(Error, PathBuf),
Parse(Error),
InvalidStructure(Error),
MissingClusterUrl,
ParseClusterUrl(InvalidUri),
ParseProxyUrl(InvalidUri),
LoadCertificateAuthority(LoadDataError),
LoadClientCertificate(LoadDataError),
LoadClientKey(LoadDataError),
ParseCertificates(PemError),
}
Available on crate feature
config
only.Expand description
Possible errors when loading kubeconfig
Variants§
CurrentContextNotSet
Failed to determine current context
KindMismatch
Kubeconfigs with mismatching kind cannot be merged
ApiVersionMismatch
Kubeconfigs with mismatching api version cannot be merged
LoadContext(String)
Failed to load current context
LoadClusterOfContext(String)
Failed to load the cluster of context
FindPath
Failed to find the path of kubeconfig
ReadConfig(Error, PathBuf)
Failed to read kubeconfig
Parse(Error)
Failed to parse kubeconfig YAML
InvalidStructure(Error)
The structure of the parsed kubeconfig is invalid
MissingClusterUrl
Cluster url is missing on selected cluster
ParseClusterUrl(InvalidUri)
Failed to parse cluster url
ParseProxyUrl(InvalidUri)
Failed to parse proxy url
LoadCertificateAuthority(LoadDataError)
Failed to load certificate authority
LoadClientCertificate(LoadDataError)
Failed to load client certificate
LoadClientKey(LoadDataError)
Failed to load client key
ParseCertificates(PemError)
Failed to parse PEM-encoded certificates
Trait Implementations§
Source§impl Debug for KubeconfigError
impl Debug for KubeconfigError
Source§impl Display for KubeconfigError
impl Display for KubeconfigError
Source§impl Error for KubeconfigError
impl Error for KubeconfigError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for KubeconfigError
impl !RefUnwindSafe for KubeconfigError
impl Send for KubeconfigError
impl Sync for KubeconfigError
impl Unpin for KubeconfigError
impl !UnwindSafe for KubeconfigError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more