forked from toolshed/abra
fix: error handling in deploy
This commit is contained in:
parent
1dca8a1067
commit
2dca602c0b
@ -61,11 +61,15 @@ upgrade <app>" command. You may pass "--force" to re-deploy the same version.
|
|||||||
if len(versions) > 0 {
|
if len(versions) > 0 {
|
||||||
version = versions[len(versions)-1]
|
version = versions[len(versions)-1]
|
||||||
logrus.Infof("choosing '%s' as version to deploy", version)
|
logrus.Infof("choosing '%s' as version to deploy", version)
|
||||||
recipe.EnsureVersion(app.Type, version)
|
if err := recipe.EnsureVersion(app.Type, version); err != nil {
|
||||||
|
logrus.Fatal(err)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
version = "latest commit"
|
version = "latest commit"
|
||||||
logrus.Warning("no versions detected, using latest commit")
|
logrus.Warning("no versions detected, using latest commit")
|
||||||
recipe.EnsureLatest(app.Type)
|
if err := recipe.EnsureLatest(app.Type); err != nil {
|
||||||
|
logrus.Fatal(err)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user