diff options
author | Daniel J Walsh <dwalsh@redhat.com> | 2022-05-23 18:10:08 -0400 |
---|---|---|
committer | Daniel J Walsh <dwalsh@redhat.com> | 2022-05-24 13:17:02 -0400 |
commit | df394b5218dc3078f2d5f9ed83ca6e4f92e738c8 (patch) | |
tree | 8cf70a04db0b6cfc177f922efb1ab72c89326f97 /test | |
parent | 2dc4f752c67e8e8c1035d6e2d689779cdc00004b (diff) | |
download | podman-df394b5218dc3078f2d5f9ed83ca6e4f92e738c8.tar.gz podman-df394b5218dc3078f2d5f9ed83ca6e4f92e738c8.tar.bz2 podman-df394b5218dc3078f2d5f9ed83ca6e4f92e738c8.zip |
Allow podman pod create to accept name argument
I am constantly attempting to add the podname to the last
argument to podman pod create. Allowing this makes it match
podman volume create and podman network create.
It does not match podman container create, since podman container create
arguments specify the arguments to run with the container.
Still need to support the --name option for backwards compatibility.
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/system/200-pod.bats | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/system/200-pod.bats b/test/system/200-pod.bats index 4250f2680..8761b7131 100644 --- a/test/system/200-pod.bats +++ b/test/system/200-pod.bats @@ -387,20 +387,20 @@ EOF is "$output" "false" "Default network sharing should be false" run_podman pod rm test - run_podman pod create --name test --share ipc --network private + run_podman pod create --share ipc --network private test run_podman pod inspect test --format {{.InfraConfig.HostNetwork}} is "$output" "false" "Private network sharing with only ipc should be false" run_podman pod rm test - run_podman pod create --name test --share net --network private - run_podman pod inspect test --format {{.InfraConfig.HostNetwork}} + local name="$(random_string 10 | tr A-Z a-z)" + run_podman pod create --name $name --share net --network private + run_podman pod inspect $name --format {{.InfraConfig.HostNetwork}} is "$output" "false" "Private network sharing with only net should be false" - run_podman pod rm test - run_podman pod create --name test --share net --network host - run_podman pod inspect test --format {{.InfraConfig.HostNetwork}} + run_podman pod create --share net --network host --replace $name + run_podman pod inspect $name --format {{.InfraConfig.HostNetwork}} is "$output" "true" "Host network sharing with only net should be true" - run_podman pod rm test + run_podman pod rm $name run_podman pod create --name test --share ipc --network host run_podman pod inspect test --format {{.InfraConfig.HostNetwork}} |