pub struct Copy {
pub opts: Vec<CopyOpt>,
pub src: Vec<String>,
pub dest: String,
}Expand description
Represents a COPY instruction
use nanite_docker::{Copy, CopyOpt};
let copy = Copy {
opts: vec![
CopyOpt::From { stage: "stage".to_string() },
CopyOpt::Link,
],
src: vec![
"src1".to_string(),
"src2".to_string(),
],
dest: "dest".to_string(),
};
let copy_built = format!("{copy}");
assert_eq!(copy_built, r#"COPY --from=stage --link "src1" "src2" "dest""#);Fields§
§opts: Vec<CopyOpt>§src: Vec<String>§dest: StringTrait Implementations§
Auto Trait Implementations§
impl Freeze for Copy
impl RefUnwindSafe for Copy
impl Send for Copy
impl Sync for Copy
impl Unpin for Copy
impl UnwindSafe for Copy
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