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

Make download timeout configurable #43

Closed
breml opened this issue Dec 3, 2021 · 3 comments · Fixed by #45
Closed

Make download timeout configurable #43

breml opened this issue Dec 3, 2021 · 3 comments · Fixed by #45

Comments

@breml
Copy link

breml commented Dec 3, 2021

I am behind a corporate proxy, which performs some security scanning on all downloads, especially archives. For archives, it will first download the whole thing, scan it and only then pass it to the client. This is done be just sending the client the first few KB and keeping the connection open until the scanning has been completed. Unfortunately, this can take quite some time, especially for big archives with lots of files (like the Go releases) and therefore, the download hits the 3 minute timeout defined in https://github.com/andrewkroh/gvm/blob/main/common/common.go#L39.

In order for me to be able to use GVM, I would need an option to configure this timeout.

@breml
Copy link
Author

breml commented Dec 3, 2021

I get the following error message:

$ time bin/gvm 1.17.4
gvm: error: failed downloading from https://storage.googleapis.com/golang/go1.17.4.linux-amd64.tar.gz: failed to write file to disk: context deadline exceeded (Client.Timeout or context cancellation while reading body)

real    9m0.413s
user    0m0.281s
sys     0m0.625s

andrewkroh added a commit that referenced this issue Jan 14, 2022
andrewkroh added a commit that referenced this issue Jan 14, 2022
@andrewkroh
Copy link
Owner

Added in #45.

@andrewkroh
Copy link
Owner

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants