summaryrefslogtreecommitdiff
path: root/libpod/container_commit.go
diff options
context:
space:
mode:
authorMatthew Heon <matthew.heon@pm.me>2019-12-05 15:11:40 -0500
committerMatthew Heon <matthew.heon@pm.me>2019-12-05 15:11:40 -0500
commit60bfa305a88c686c91ebc0f8f98ac14405ae10cf (patch)
treeb83e8a8c2decb9fc831d818a6d10824115251b9e /libpod/container_commit.go
parentc4fbd2fc9489b318298ada61e4f98d0097bc0b0d (diff)
downloadpodman-60bfa305a88c686c91ebc0f8f98ac14405ae10cf.tar.gz
podman-60bfa305a88c686c91ebc0f8f98ac14405ae10cf.tar.bz2
podman-60bfa305a88c686c91ebc0f8f98ac14405ae10cf.zip
Add ONBUILD support to --change
Return types had to change a bit for this, but since we can wrap the old v1.ImageConfig, changes are overall not particularly bad. At present, I believe this only works with commit, not import. This matches how things were before we changed to the new parsing so I think this is fine. Signed-off-by: Matthew Heon <matthew.heon@pm.me>
Diffstat (limited to 'libpod/container_commit.go')
-rw-r--r--libpod/container_commit.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/libpod/container_commit.go b/libpod/container_commit.go
index cab204546..a0ba57f4f 100644
--- a/libpod/container_commit.go
+++ b/libpod/container_commit.go
@@ -183,6 +183,9 @@ func (c *Container) Commit(ctx context.Context, destImage string, options Contai
if newImageConfig.StopSignal != "" {
importBuilder.SetStopSignal(newImageConfig.StopSignal)
}
+ for _, onbuild := range newImageConfig.OnBuild {
+ importBuilder.SetOnBuild(onbuild)
+ }
candidates, _, _, err := util.ResolveName(destImage, "", sc, c.runtime.store)
if err != nil {