Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skip healthcheck #113

Merged
merged 7 commits into from
Sep 19, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ var (
// dryRun Defaults to false
dryRun bool

// skipChecks Defaults to false
skipChecks bool

// deleteReources bool
deleteResources bool

Expand Down Expand Up @@ -120,6 +123,11 @@ func main() {
Usage: "if true, the server's certificate will not be checked for validity",
EnvVar: "INSECURE_SKIP_TLS_VERIFY,PLUGIN_INSECURE_SKIP_TLS_VERIFY",
},
cli.BoolFlag{
Name: "skip-checks",
Usage: "if true, the resources will be deployed without a subsequent healthcheck",
Destination: &skipChecks,
},
cli.StringFlag{
Name: FlagKubeConfigData,
Usage: "Kubernetes config file data",
Expand Down Expand Up @@ -641,7 +649,7 @@ func deploy(c *cli.Context, r *ObjectResource) error {
r.Name = strings.Split(resourceName, "/")[1]
}

if !c.Bool(FlagDelete) && isWatchableResouce(r) {
if !c.Bool(FlagDelete) && isWatchableResouce(r) && !skipChecks {
return watchResource(c, r)
}
return nil
Expand Down