github.com/octohelm/wagon@v0.0.0-20240308040401-88662650dc0b/pkg/engine/plan/task/container_set.go (about) 1 package task 2 3 import ( 4 "github.com/octohelm/wagon/pkg/engine/plan/task/core" 5 "golang.org/x/net/context" 6 ) 7 8 func init() { 9 core.DefaultFactory.Register(&Set{}) 10 } 11 12 type Set struct { 13 core.Task 14 15 Input core.ImageConfig `json:"input"` 16 Config core.ImageConfig `json:"config"` 17 Output core.ImageConfig `json:"-" wagon:"generated,name=output"` 18 } 19 20 func (e *Set) Do(ctx context.Context) error { 21 e.Output = e.Input.Merge(e.Config) 22 return nil 23 }