MCPcopy Index your code
hub / github.com/dagger/container-use / UpdateConfig

Method UpdateConfig

environment/environment.go:220–234  ·  view source on GitHub ↗
(ctx context.Context, newConfig *EnvironmentConfig)

Source from the content-addressed store, hash-verified

218}
219
220func (env *Environment) UpdateConfig(ctx context.Context, newConfig *EnvironmentConfig) error {
221 env.State.Config = newConfig
222
223 // Re-build the base image with the new config
224 container, err := env.buildBase(ctx, env.Workdir())
225 if err != nil {
226 return err
227 }
228
229 if err := env.apply(ctx, container); err != nil {
230 return err
231 }
232
233 return nil
234}
235
236func (env *Environment) Run(ctx context.Context, command, shell string, useEntrypoint bool) (string, error) {
237 args := []string{}

Callers 2

UpdateEnvironmentMethod · 0.80

Calls 3

buildBaseMethod · 0.95
WorkdirMethod · 0.95
applyMethod · 0.95

Tested by

no test coverage detected