Elastic agent does not use custom Agent Binary Download settings set in Fleet policy.
How to reproduce:
- Create a non-existing Proxy setting in Fleet (the URL is not important, just check that there's nothing listening for that URL)

- Create a new
Agent Binary Download entry using the non-existing Proxy created at the previous step

- Create a Fleet policy that uses the new
Agent Binary Download entry

- Trigger an upgrade from one of the affected version (tested this on
9.1.4 linux/amd64 elastic-agent) and see the upgrade succeeding even though the configured proxy is not there. The expected behavior is for the upgrade to fail since the packages cannot be downloaded using a non-existing proxy
This bug has been introduced with #9122: in that PR the following behavior has been implemented
Elastic agent does not use custom
Agent Binary Downloadsettings set in Fleet policy.How to reproduce:
Agent Binary Downloadentry using the non-existing Proxy created at the previous stepAgent Binary Downloadentry9.1.4linux/amd64 elastic-agent) and see the upgrade succeeding even though the configured proxy is not there. The expected behavior is for the upgrade to fail since the packages cannot be downloaded using a non-existing proxyThis bug has been introduced with #9122: in that PR the following behavior has been implemented
artifactDownloaderis created only once when theUpgraderis instantiated at application startup