pub struct ImageProxyConfig {
    pub authfile: Option<PathBuf>,
    pub auth_data: Option<File>,
    pub auth_anonymous: bool,
    pub certificate_directory: Option<PathBuf>,
    pub insecure_skip_tls_verification: Option<bool>,
    pub skopeo_cmd: Option<Command>,
}
Expand description

Configuration for the proxy.

We re-export this rather than inventing our own wrapper in the interest of avoiding duplication. Configuration for the proxy.

Fields§

§authfile: Option<PathBuf>

Path to container auth file; equivalent to skopeo --authfile. This conflicts with [auth_data].

§auth_data: Option<File>

Data stream for container auth. This conflicts with [authfile].

§auth_anonymous: bool

Do not use default container authentication paths; equivalent to skopeo --no-creds.

Defaults to false; in other words, use the default file paths from man containers-auth.json.

§certificate_directory: Option<PathBuf>§insecure_skip_tls_verification: Option<bool>

If set, disable TLS verification. Equivalent to skopeo --tls-verify=false.

§skopeo_cmd: Option<Command>

Provide a configured std::process::Command instance.

This allows configuring aspects of the resulting child skopeo process. The intention of this hook is to allow the caller to use e.g. systemd-run or equivalent containerization tools. For example you can set up a command whose arguments are systemd-run -Pq -p DynamicUser=yes -- skopeo. You can also set up arbitrary aspects of the child via e.g. current_dir pre_exec.

The default is to wrap via util-linux setpriv --pdeathsig SIGTERM -- skopeo, which on Linux binds the lifecycle of the child process to the parent.

Note that you must add skopeo as the primary argument or indirectly. However, all other command line options including experimental-image-proxy will be injected by this library. You may use a different command name from skopeo if your application has set up a compatible copy, e.g. /usr/lib/myapp/my-private-skopeo/

Trait Implementations§

source§

impl Debug for ImageProxyConfig

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Default for ImageProxyConfig

source§

fn default() -> ImageProxyConfig

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more