do not assume intput is a compose file on .env parsing error
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
This commit is contained in:
+1
-1
@@ -259,7 +259,7 @@ func loadComposeFiles(cfgs []composetypes.ConfigFile, envs map[string]string, op
|
|||||||
func validateComposeFile(dt []byte, fn string) (bool, error) {
|
func validateComposeFile(dt []byte, fn string) (bool, error) {
|
||||||
envs, err := composeEnv()
|
envs, err := composeEnv()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return true, err
|
return false, err
|
||||||
}
|
}
|
||||||
fnl := strings.ToLower(fn)
|
fnl := strings.ToLower(fn)
|
||||||
if strings.HasSuffix(fnl, ".yml") || strings.HasSuffix(fnl, ".yaml") {
|
if strings.HasSuffix(fnl, ".yml") || strings.HasSuffix(fnl, ".yaml") {
|
||||||
|
|||||||
Reference in New Issue
Block a user