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

feature: add a timeout on the rollout status watch #3089

Merged
merged 1 commit into from
Mar 29, 2022

Conversation

shreddedbacon
Copy link
Member

Checklist

  • Affected Issues have been mentioned in the Closing issues section
  • Documentation has been written/updated
  • PR title is ready for changelog and subsystem label(s) applied

Sometimes kubectl rollout status can get stuck indefinitely waiting for a rollout to complete due to an issue with the previous pod in the existing replicaset possibly not terminating.

Adding a --timeout=1200s to this status check is double what the progressDeadlineSeconds value is, and if a pod rollout is taking more than 20 minutes to complete, there is probably something wrong anyway.

Closing issues

Partially closes #2861 as it won't actually report on a long running notification, but will prevent the condition where a long running deployment would occur. With intermittent build logs now, it can be more obvious where a build has stalled, before calling it "long running"

@seanhamlin
Copy link
Contributor

Confirming this does what we expect (altered the timeout to be lower for testing):

$ kubectl -n ns-dev rollout status deployment solr --watch --timeout=1m
Waiting for deployment "solr" rollout to finish: 0 out of 1 new replicas have been updated...
error: timed out waiting for the condition

$ echo $?
1

@tobybellwood tobybellwood merged commit 24c580d into main Mar 29, 2022
@tobybellwood tobybellwood deleted the rollout-timeout branch March 29, 2022 06:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Prevent long running (failed) deployments where practical
3 participants