get.porter.sh/porter@v1.3.0/pkg/exec/exec.go (about) 1 package exec 2 3 import ( 4 "get.porter.sh/porter/pkg/runtime" 5 ) 6 7 // Mixin is the logic behind the exec mixin 8 type Mixin struct { 9 // Config is a specialized portercontext.Context with additional runtime settings. 10 Config runtime.RuntimeConfig 11 12 // Debug specifies if the mixin should be in debug mode 13 Debug bool 14 } 15 16 // New exec mixin client, initialized with useful defaults. 17 func New() *Mixin { 18 return &Mixin{ 19 Config: runtime.NewConfig(), 20 } 21 } 22 23 // Close releases resources held by the mixin, such as our logging and tracing 24 // connections. 25 func (m *Mixin) Close() { 26 m.Config.Close() 27 }