diff options
author | Daniel J Walsh <dwalsh@redhat.com> | 2021-01-28 15:34:35 -0500 |
---|---|---|
committer | Daniel J Walsh <dwalsh@redhat.com> | 2021-01-29 08:48:35 -0500 |
commit | d7c356552e3c3d1710f22da2f710f9ad529c2ad9 (patch) | |
tree | 2143e634af0203c47a10301da6be13518c3a7799 /pkg/bindings/images | |
parent | 0c6a889a7ec93964a12a10870920727e13e438c3 (diff) | |
download | podman-d7c356552e3c3d1710f22da2f710f9ad529c2ad9.tar.gz podman-d7c356552e3c3d1710f22da2f710f9ad529c2ad9.tar.bz2 podman-d7c356552e3c3d1710f22da2f710f9ad529c2ad9.zip |
Podman-remote push can support --format
Fix man page to document podman push --format fully.
Also found that push was not handling the tlsverify so fixed this.
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'pkg/bindings/images')
-rw-r--r-- | pkg/bindings/images/types.go | 2 | ||||
-rw-r--r-- | pkg/bindings/images/types_push_options.go | 16 |
2 files changed, 18 insertions, 0 deletions
diff --git a/pkg/bindings/images/types.go b/pkg/bindings/images/types.go index 75f1a2f81..2cec9ee71 100644 --- a/pkg/bindings/images/types.go +++ b/pkg/bindings/images/types.go @@ -106,6 +106,8 @@ type PushOptions struct { Authfile *string // Compress tarball image layers when pushing to a directory using the 'dir' transport. Compress *bool + // Manifest type of the pushed image + Format *string // Password for authenticating against the registry. Password *string // SkipTLSVerify to skip HTTPS and certificate verification. diff --git a/pkg/bindings/images/types_push_options.go b/pkg/bindings/images/types_push_options.go index 7f9bb1064..b7d8a6f2d 100644 --- a/pkg/bindings/images/types_push_options.go +++ b/pkg/bindings/images/types_push_options.go @@ -135,6 +135,22 @@ func (o *PushOptions) GetCompress() bool { return *o.Compress } +// WithFormat +func (o *PushOptions) WithFormat(value string) *PushOptions { + v := &value + o.Format = v + return o +} + +// GetFormat +func (o *PushOptions) GetFormat() string { + var format string + if o.Format == nil { + return format + } + return *o.Format +} + // WithPassword func (o *PushOptions) WithPassword(value string) *PushOptions { v := &value |