pub struct CredentialHelper { /* private fields */ }Expand description
A credential helper that can retrieve credentials for registries.
Implementations§
Source§impl CredentialHelper
impl CredentialHelper
Sourcepub fn new(name: impl Into<String>) -> Self
pub fn new(name: impl Into<String>) -> Self
Creates a new credential helper with the given name.
The helper will be invoked as docker-credential-{name}.
Sourcepub fn get(&self, server_url: &str) -> Result<Credential>
pub fn get(&self, server_url: &str) -> Result<Credential>
Gets credentials for a registry server.
Invokes the helper with the “get” action, passing the server URL via stdin.
Sourcepub fn is_available(&self) -> bool
pub fn is_available(&self) -> bool
Checks if the helper binary exists and is executable.
Trait Implementations§
Source§impl Clone for CredentialHelper
impl Clone for CredentialHelper
Source§fn clone(&self) -> CredentialHelper
fn clone(&self) -> CredentialHelper
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for CredentialHelper
impl RefUnwindSafe for CredentialHelper
impl Send for CredentialHelper
impl Sync for CredentialHelper
impl Unpin for CredentialHelper
impl UnsafeUnpin for CredentialHelper
impl UnwindSafe for CredentialHelper
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