Skip to content

Use specified 'pod-creation-timeout' in Kubernetes API requests#111

Open
machadovilaca wants to merge 1 commit into
eldadru:masterfrom
machadovilaca:jv/use-pod-creation-timeout
Open

Use specified 'pod-creation-timeout' in Kubernetes API requests#111
machadovilaca wants to merge 1 commit into
eldadru:masterfrom
machadovilaca:jv/use-pod-creation-timeout

Conversation

@machadovilaca

@machadovilaca machadovilaca commented Apr 16, 2021

Copy link
Copy Markdown

Flag '--pod-creation-timeout' was not being respected when requesting the creation of the pod to the Kubernetes API resulting in

Error: Post https://<url>/api/v1/namespaces/<namespace>/pods?timeout=30s: context deadline exceeded (Client.Timeout exceeded while awaiting headers)

@machadovilaca

Copy link
Copy Markdown
Author

Any feedback?

@bostrt bostrt self-assigned this Jul 27, 2022
@bostrt

bostrt commented Jul 27, 2022

Copy link
Copy Markdown
Contributor

Ksniff's --pod-creation-timeout right now only waits for the privileged pod to startup, after being initially created. In other words, there is not a timeout flag for the POST that creates the Pod initially (as you have pointed out with the error msg).

A downside I see to the change in this PR is that a user could potentially wait for --pod-creation-timeout twice; once during the POST and again during pod startup.

@machadovilaca what do you think about creating a new/separate --request-timeout flag that mimics the kubectl flag of the same name?

For reference:

$ kubectl options  | grep request-timeout
      --request-timeout='0': The length of time to wait before giving up on a single server request. Non-zero values should contain a corresponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't timeout requests.

@mgerasimchuk

Copy link
Copy Markdown

Faced the same problem, the --request-timeout flag will be helpful

@mgerasimchuk

Copy link
Copy Markdown

Proposed another option adding the --request-timeout flag: #179 (comment)

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.

3 participants