forked from toolshed/abra
fix: retain backwards compat with TYPE/RECIPE change
This commit is contained in:
@ -35,16 +35,21 @@ func LoadComposefile(opts Deploy, appEnv map[string]string) (*composetypes.Confi
|
||||
return nil, err
|
||||
}
|
||||
|
||||
recipeName, exists := appEnv["RECIPE"]
|
||||
if !exists {
|
||||
recipeName, _ = appEnv["TYPE"]
|
||||
}
|
||||
|
||||
unsupportedProperties := loader.GetUnsupportedProperties(dicts...)
|
||||
if len(unsupportedProperties) > 0 {
|
||||
logrus.Warnf("%s: ignoring unsupported options: %s",
|
||||
appEnv["RECIPE"], strings.Join(unsupportedProperties, ", "))
|
||||
recipeName, strings.Join(unsupportedProperties, ", "))
|
||||
}
|
||||
|
||||
deprecatedProperties := loader.GetDeprecatedProperties(dicts...)
|
||||
if len(deprecatedProperties) > 0 {
|
||||
logrus.Warnf("%s: ignoring deprecated options: %s",
|
||||
appEnv["RECIPE"], propertyWarnings(deprecatedProperties))
|
||||
recipeName, propertyWarnings(deprecatedProperties))
|
||||
}
|
||||
return config, nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user