Conversation
1c30d58 to
56ace39
Compare
There was a problem hiding this comment.
Seems fine to me, show-notes worked.
Did an install with 1-second timeout (./rancher app install --wait --timeout 1 redis) and got:
[kube] 2019/07/22 13:24:20 creating 5 resource(s)
[kube] 2019/07/22 13:24:20 beginning wait for 5 resources with timeout of 1s
[kube] 2019/07/22 13:24:21 Pod is not ready: redis-0f4gh/a-svj2n-redis-master-0
[tiller] 2019/07/22 13:24:21 warning: Release "a-svj2n" failed: timed out waiting for the condition
[storage] 2019/07/22 13:24:21 updating release "a-svj2n.v1"
[tiller] 2019/07/22 13:24:21 failed install perform step: release a-svj2n failed: timed out waiting for the condition
2019/07/22 13:24:21 [ERROR] AppController p-tnfj6/a-svj2n [helm-controller] failed with : failed to install app a-svj2n. Error: release a-svj2n failed: timed out waiting for the condition
| @@ -177,6 +177,15 @@ func AppCommand() cli.Command { | |||
| Name: "no-prompt", | |||
There was a problem hiding this comment.
Could add an example in description that includes these flags
cmd/app.go
Outdated
| break | ||
| } | ||
| } | ||
| fmt.Printf("run \"app show-notes %s\" to view app notes once app is ready", madeApp.Name) |
There was a problem hiding this comment.
Tested and it works, looks good except that I think it should have newline at end. If there is ever another print statement below it then both would be on same line. Current output:
run "app show-notes a-gjlhj" to view app notes once app is ready%
| app.TargetNamespace = namespace | ||
| } | ||
|
|
||
| app.Wait = ctx.Bool("wait") |
There was a problem hiding this comment.
should wait boolflag have a default of true? false? what happens if you set app.Wait to nil or whatever comes through from the not setting BoolFlag Value?
There was a problem hiding this comment.
default on bool flags is false, which is intended. I tested without using wait.
|
lgtm |
Added wait and timeout flags. Added show-notes flag. Prior, there was no way to tell helm to wait longer than the default of 300 seconds. This caused installs of certain apps to fail. Now, users can configure the amount of time helm should wait before failing. CLI no longer hangs while waiting for helm. User can use the existing wait command for hanging behavior. Notes may not be ready immediately, so user can now use the show-notes flag to print app notes at any time after app creation.
|
lgtm |
Problem:
Some apps require wait and timeout flags to be passed to helm. CLI does not support these flags for apps.
Solution:
Accept flags for wait and timeout and then pass them to helm.
Depends on following PRs:
types - rancher/types#911
rancher - rancher/rancher#21604
intended merge order:
types -> rancher -> cli
Issue:
rancher/rancher#17471