We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dfd76b3 commit 6f8fb9eCopy full SHA for 6f8fb9e
1 file changed
container_opts.go
@@ -78,6 +78,14 @@ func WithImage(i Image) NewContainerOpts {
78
}
79
80
81
+// WithImageName allows setting the image name as the base for the container
82
+func WithImageName(n string) NewContainerOpts {
83
+ return func(ctx context.Context, _ *Client, c *containers.Container) error {
84
+ c.Image = n
85
+ return nil
86
+ }
87
+}
88
+
89
// WithContainerLabels adds the provided labels to the container
90
func WithContainerLabels(labels map[string]string) NewContainerOpts {
91
return func(_ context.Context, _ *Client, c *containers.Container) error {
0 commit comments