fix: only check host keys on requested hosts
All checks were successful
continuous-integration/drone/push Build is passing

See coop-cloud/organising#242.
This commit is contained in:
2021-11-09 17:43:24 +01:00
parent 17a5f1529a
commit 6f26b51f3e
5 changed files with 22 additions and 17 deletions

View File

@ -8,6 +8,7 @@ import (
"coopcloud.tech/abra/pkg/catalogue"
"coopcloud.tech/abra/pkg/config"
"coopcloud.tech/abra/pkg/recipe"
"coopcloud.tech/abra/pkg/ssh"
"github.com/AlecAivazis/survey/v2"
"github.com/sirupsen/logrus"
"github.com/urfave/cli/v2"
@ -98,6 +99,10 @@ func ValidateApp(c *cli.Context) config.App {
logrus.Fatal(err)
}
if err := ssh.EnsureHostKey(app.Server); err != nil {
logrus.Fatal(err)
}
logrus.Debugf("validated '%s' as app argument", appName)
return app