pub enum SecretEnvError {
Show 19 variants
Conflict {
name: String,
file_var: String,
},
CommandConflict {
set: Vec<String>,
},
CommandSplit {
command_var: String,
reason: &'static str,
},
CommandSpawn {
command_var: String,
program: String,
hint: &'static str,
source: Error,
},
CommandFailed {
command_var: String,
program: String,
status: String,
detail: String,
},
CommandTimedOut {
command_var: String,
program: String,
secs: u64,
},
CommandOutputTooLarge {
command_var: String,
program: String,
limit: usize,
},
CommandEmptyOutput {
command_var: String,
program: String,
},
CommandNotUtf8 {
command_var: String,
program: String,
},
RelativePath {
file_var: String,
path: PathBuf,
},
Unreadable {
file_var: String,
path: PathBuf,
source: Error,
},
Unwritable {
file_var: String,
path: PathBuf,
source: Error,
},
HoldsJson {
file_var: String,
path: PathBuf,
},
NotAFile {
file_var: String,
path: PathBuf,
},
Empty {
file_var: String,
path: PathBuf,
},
NotUtf8 {
file_var: String,
path: PathBuf,
},
LoosePermissions {
file_var: String,
path: PathBuf,
mode: u32,
},
WritableByOthers {
file_var: String,
path: PathBuf,
mode: u32,
},
WrongOwner {
file_var: String,
path: PathBuf,
owner: u32,
expected: u32,
},
}Expand description
Why a secret could not be resolved. Messages name variables, paths, modes and uids only — never the secret’s bytes.
Variants§
Conflict
NAME and NAME_FILE are both set in the same layer.
CommandConflict
Two or more of NAME, NAME_FILE and NAME_COMMAND are set in the
same layer, at least one of them the command.
CommandSplit
The _COMMAND value cannot be split into a program and arguments.
Fields
CommandSpawn
The command’s program could not be started.
Fields
CommandFailed
The command ran but did not exit successfully.
Fields
CommandTimedOut
The command did not finish in time and was killed.
Fields
CommandOutputTooLarge
The command wrote more than the accepted amount to standard output.
Fields
CommandEmptyOutput
The command succeeded but wrote nothing (after trimming one newline).
Fields
CommandNotUtf8
The command’s output is not valid UTF-8.
Fields
RelativePath
The _FILE value is not an absolute path.
Unreadable
The file could not be opened, inspected, or read.
Fields
Unwritable
The file could not be written.
Fields
HoldsJson
An existing secret file to be replaced holds JSON, which no secret
this resolver stores does: most likely a client_secret.json.
NotAFile
The path (after following symlinks) is not a regular file.
Empty
The file is empty (after trimming one trailing newline).
NotUtf8
The file’s contents are not valid UTF-8.
LoosePermissions
A file owned by the current user grants group or other permission bits.
Fields
WritableByOthers
A root-owned file that group or other users can write.
Fields
WrongOwner
The file is owned by neither the current user nor root.
Trait Implementations§
Source§impl Debug for SecretEnvError
impl Debug for SecretEnvError
Source§impl Display for SecretEnvError
impl Display for SecretEnvError
Source§impl Error for SecretEnvError
impl Error for SecretEnvError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for SecretEnvError
impl !UnwindSafe for SecretEnvError
impl Freeze for SecretEnvError
impl Send for SecretEnvError
impl Sync for SecretEnvError
impl Unpin for SecretEnvError
impl UnsafeUnpin for SecretEnvError
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
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> ⓘ
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> ⓘ
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 moreSource§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
Source§fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
ToCompactString::to_compact_string() Read moreSource§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
CompactString. Read moreSource§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.