pub struct PullArgs {
pub image: String,
pub username: Option<String>,
pub password: Option<String>,
pub skip_tls: bool,
pub cache_dir: PathBuf,
pub verbose: bool,
pub timeout: u64,
pub max_concurrent: usize,
}
Expand description
拉取镜像的参数
Fields§
§image: String
完整镜像引用 (支持多种格式):
- docker.io/library/ubuntu:latest
- ubuntu:latest (默认使用 docker.io/library)
- ubuntu (默认标签 latest)
username: Option<String>
Registry 用户名
password: Option<String>
Registry 密码
skip_tls: bool
跳过 TLS 证书验证
cache_dir: PathBuf
缓存目录 (默认: .cache)
verbose: bool
启用详细输出
timeout: u64
超时时间(秒)
max_concurrent: usize
最大并发下载数 (可以使用 –concurrent 作为别名)
Implementations§
Trait Implementations§
Source§impl Args for PullArgs
impl Args for PullArgs
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Append to
Command
so it can instantiate self
via
FromArgMatches::update_from_arg_matches_mut
Read moreSource§impl FromArgMatches for PullArgs
impl FromArgMatches for PullArgs
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
Assign values from
ArgMatches
to self
.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
Assign values from
ArgMatches
to self
.Auto Trait Implementations§
impl Freeze for PullArgs
impl RefUnwindSafe for PullArgs
impl Send for PullArgs
impl Sync for PullArgs
impl Unpin for PullArgs
impl UnwindSafe for PullArgs
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