mirror of
https://github.com/containers/podman.git
synced 2025-06-24 19:42:56 +08:00
cli: podman run/create --env-file use StringArray()
This option accepts a file path so we should allow commas in it. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
This commit is contained in:
@ -147,7 +147,7 @@ func DefineCreateFlags(cmd *cobra.Command, cf *entities.ContainerCreateOptions,
|
|||||||
}
|
}
|
||||||
|
|
||||||
envFileFlagName := "env-file"
|
envFileFlagName := "env-file"
|
||||||
createFlags.StringSliceVar(
|
createFlags.StringArrayVar(
|
||||||
&cf.EnvFile,
|
&cf.EnvFile,
|
||||||
envFileFlagName, []string{},
|
envFileFlagName, []string{},
|
||||||
"Read in a file of environment variables",
|
"Read in a file of environment variables",
|
||||||
|
@ -196,7 +196,7 @@ EOF
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Same, with --env-file
|
# Same, with --env-file
|
||||||
local envfile="$PODMAN_TMPDIR/envfile-in-1"
|
local envfile="$PODMAN_TMPDIR/envfile-in-1,withcomma"
|
||||||
cat >$envfile <<EOF
|
cat >$envfile <<EOF
|
||||||
$prefix*
|
$prefix*
|
||||||
NOT*DEFINED
|
NOT*DEFINED
|
||||||
|
Reference in New Issue
Block a user