|
|
@@ -170,7 +170,7 @@ func (o *ProjectOptions) WithServices(dockerCli command.Cli, fn ProjectServicesF
|
|
|
return Adapt(func(ctx context.Context, args []string) error {
|
|
|
options := []cli.ProjectOptionsFn{
|
|
|
cli.WithResolvedPaths(true),
|
|
|
- cli.WithDiscardEnvFile,
|
|
|
+ cli.WithoutEnvironmentResolution,
|
|
|
}
|
|
|
|
|
|
project, metrics, err := o.ToProject(ctx, dockerCli, args, options...)
|
|
|
@@ -180,6 +180,11 @@ func (o *ProjectOptions) WithServices(dockerCli command.Cli, fn ProjectServicesF
|
|
|
|
|
|
ctx = context.WithValue(ctx, tracing.MetricsKey{}, metrics)
|
|
|
|
|
|
+ project, err = project.WithServicesEnvironmentResolved(true)
|
|
|
+ if err != nil {
|
|
|
+ return err
|
|
|
+ }
|
|
|
+
|
|
|
return fn(ctx, project, args)
|
|
|
})
|
|
|
}
|