mirror of
https://github.com/containers/podman.git
synced 2025-08-06 03:19:52 +08:00
volume: new options [no]copy
add two new options to the volume create command: copy and nocopy. When nocopy is specified, the files from the container image are not copied up to the volume. Closes: https://github.com/containers/podman/issues/14722 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
@ -55,6 +55,12 @@ func (v *Volume) needsMount() bool {
|
||||
if _, ok := v.config.Options["NOQUOTA"]; ok {
|
||||
index++
|
||||
}
|
||||
if _, ok := v.config.Options["nocopy"]; ok {
|
||||
index++
|
||||
}
|
||||
if _, ok := v.config.Options["copy"]; ok {
|
||||
index++
|
||||
}
|
||||
// when uid or gid is set there is also the "o" option
|
||||
// set so we have to ignore this one as well
|
||||
if index > 0 {
|
||||
|
Reference in New Issue
Block a user