diff --git a/changes/27548-installer-download-fail b/changes/27548-installer-download-fail new file mode 100644 index 0000000000..2e50e737a4 --- /dev/null +++ b/changes/27548-installer-download-fail @@ -0,0 +1 @@ +- Fixed software installer download errors by extending the timeout for the download endpoints. \ No newline at end of file diff --git a/cmd/fleet/serve.go b/cmd/fleet/serve.go index 277861d21b..699575e7d9 100644 --- a/cmd/fleet/serve.go +++ b/cmd/fleet/serve.go @@ -1218,7 +1218,9 @@ the way that the Fleet server works. if (req.Method == http.MethodPost && strings.HasSuffix(req.URL.Path, "/fleet/software/package")) || (req.Method == http.MethodPatch && strings.HasSuffix(req.URL.Path, "/package") && strings.Contains(req.URL.Path, "/fleet/software/titles/")) || - (req.Method == http.MethodPost && strings.HasSuffix(req.URL.Path, "/bootstrap")) { + (req.Method == http.MethodPost && strings.HasSuffix(req.URL.Path, "/bootstrap")) || + (req.Method == http.MethodGet && strings.Contains(req.URL.Path, "/package/token")) || + (req.Method == http.MethodPost && strings.Contains(req.URL.Path, "orbit/software_install/package")) { var zeroTime time.Time rc := http.NewResponseController(rw) // For large software installers and bootstrap packages, the server time needs time to read the full