diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2019-11-07 20:26:14 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-07 20:26:14 +0100 |
commit | d919961f621d0b9eb70b971fc8e8915ee279ab60 (patch) | |
tree | 05272b838219ba06a56c4d06038ae2f7d6fa1fe1 /cmd/podman | |
parent | 347499778cb1a7045dc831f99b9539bc20fe008d (diff) | |
parent | 82e4116e578f72bd627330ac10d541c3e234738c (diff) | |
download | podman-d919961f621d0b9eb70b971fc8e8915ee279ab60.tar.gz podman-d919961f621d0b9eb70b971fc8e8915ee279ab60.tar.bz2 podman-d919961f621d0b9eb70b971fc8e8915ee279ab60.zip |
Merge pull request #4451 from giuseppe/set-mac
podman: add support for specifying MAC
Diffstat (limited to 'cmd/podman')
-rw-r--r-- | cmd/podman/cliconfig/config.go | 17 | ||||
-rw-r--r-- | cmd/podman/common.go | 2 | ||||
-rw-r--r-- | cmd/podman/restore.go | 1 | ||||
-rw-r--r-- | cmd/podman/shared/create.go | 4 |
4 files changed, 11 insertions, 13 deletions
diff --git a/cmd/podman/cliconfig/config.go b/cmd/podman/cliconfig/config.go index 58d67ddc1..780b68333 100644 --- a/cmd/podman/cliconfig/config.go +++ b/cmd/podman/cliconfig/config.go @@ -467,14 +467,15 @@ type RestartValues struct { type RestoreValues struct { PodmanCommand - All bool - Keep bool - Latest bool - TcpEstablished bool - Import string - Name string - IgnoreRootfs bool - IgnoreStaticIP bool + All bool + Keep bool + Latest bool + TcpEstablished bool + Import string + Name string + IgnoreRootfs bool + IgnoreStaticIP bool + IgnoreStaticMAC bool } type RmValues struct { diff --git a/cmd/podman/common.go b/cmd/podman/common.go index 8afbe2e0b..3e86b8e20 100644 --- a/cmd/podman/common.go +++ b/cmd/podman/common.go @@ -328,7 +328,7 @@ func getCreateFlags(c *cliconfig.PodmanCommand) { ) createFlags.String( "mac-address", "", - "Container MAC address (e.g. 92:d0:c6:0a:29:33), not currently supported", + "Container MAC address (e.g. 92:d0:c6:0a:29:33)", ) createFlags.StringP( "memory", "m", "", diff --git a/cmd/podman/restore.go b/cmd/podman/restore.go index 90d0b2dc4..caefadb6d 100644 --- a/cmd/podman/restore.go +++ b/cmd/podman/restore.go @@ -47,6 +47,7 @@ func init() { flags.StringVarP(&restoreCommand.Name, "name", "n", "", "Specify new name for container restored from exported checkpoint (only works with --import)") flags.BoolVar(&restoreCommand.IgnoreRootfs, "ignore-rootfs", false, "Do not apply root file-system changes when importing from exported checkpoint") flags.BoolVar(&restoreCommand.IgnoreStaticIP, "ignore-static-ip", false, "Ignore IP address set via --static-ip") + flags.BoolVar(&restoreCommand.IgnoreStaticMAC, "ignore-static-mac", false, "Ignore MAC address set via --mac-address") markFlagHiddenForRemoteClient("latest", flags) } diff --git a/cmd/podman/shared/create.go b/cmd/podman/shared/create.go index dc343e694..6c74b8a9b 100644 --- a/cmd/podman/shared/create.go +++ b/cmd/podman/shared/create.go @@ -336,10 +336,6 @@ func ParseCreateOpts(ctx context.Context, c *GenericCLIResults, runtime *libpod. return nil, err } - if c.String("mac-address") != "" { - return nil, errors.Errorf("--mac-address option not currently supported") - } - imageID := "" inputCommand = c.InputArgs[1:] |