pub enum Error {
Show 15 variants
Config(Error),
CommandNonZero {
exit_status: ExitStatus,
stderr: String,
},
FailedU32ToUsizeConversion,
NoForceCommandForMapping {
nethsm_users: Vec<String>,
system_user: String,
},
NoProcess,
NotRoot,
NoUidForProcess(usize),
SysUidFromStr(String),
TmpfilesDPath {
path: String,
user: SystemUserId,
reason: &'static str,
},
UserAdd {
user: SystemUserId,
source: Error,
},
UserMod {
user: SystemUserId,
source: Error,
},
UserNameConversion {
user: SystemUserId,
source: Error,
},
WriteAuthorizedKeys {
user: SystemUserId,
source: Error,
},
WriteSshdConfig {
user: SystemUserId,
source: Error,
},
WriteTmpfilesD {
user: SystemUserId,
source: Error,
},
}
Variants§
Config(Error)
A config error
CommandNonZero
A Command
exited unsuccessfully
FailedU32ToUsizeConversion
A u32
value can not be converted to usize
on the current platform
NoForceCommandForMapping
There is no SSH ForceCommand defined for a UserMapping
NoProcess
No process information could be retrieved from the current PID
NotRoot
The application is not run as root
NoUidForProcess(usize)
No process information could be retrieved from the current PID
SysUidFromStr(String)
A string could not be converted to a sysinfo::Uid
TmpfilesDPath
A Path
value for a tmpfiles.d integration is not valid.
UserAdd
Adding a user failed
UserMod
Modifying a user failed
UserNameConversion
A system user name can not be derived from a configuration user name
WriteAuthorizedKeys
Writing authorized_keys file for user failed
WriteSshdConfig
Writing sshd_config drop-in file for user failed
WriteTmpfilesD
Writing tmpfiles.d integration for user failed
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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 Error
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
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