program: Skip warning inside docker

This commit is contained in:
Tom Wiesing 2022-09-13 17:06:15 +02:00
parent f674e50e10
commit ee330682d9
No known key found for this signature in database

View file

@ -39,13 +39,11 @@ func NewProgram() Program {
return errUserIsNotRoot
}
// warn when not using the distillery excutable
if context.Description.Requirements.NeedsDistillery {
dis := context.Environment
if !dis.UsingDistilleryExecutable() {
// when not running inside docker and we need a distillery
// then we should warn if we are not using the distillery executable.
if dis := context.Environment; !context.Args.Flags.InternalInDocker && context.Description.Requirements.NeedsDistillery && !dis.UsingDistilleryExecutable() {
context.EPrintf(warnNoDeployWdcli, core.Executable, dis.ExecutablePath())
}
}
return nil
},