config: Set the default value of the network_http_proxy_uri setting via the http_proxy variable#41209
Conversation
Signed-off-by: Narfinger <[email protected]>
mrobinson
left a comment
There was a problem hiding this comment.
I believe that handling of the pretty standard http_proxy environment variable should be handled automatically by Servo, allowing the embedder to override the value when necessary.
Signed-off-by: Narfinger <[email protected]>
|
Ok I moved it to the servo Preferences now. Let me know if there is something else that should change. |
network_http_proxy_uri setting via the http_proxy variable
Huh, the change was that simple 😆 - Now I feel stupid. |
No worries. Eventually Servo will need a more complex proxy resolution API allowing the client to override the settings with a URL or a local PAC file, but I guess this is good enough for now. Plus, this should work automatically with anyone embedding Servo. In the future, it is likely we will make it so that the default |
|
This does not read |
follow up to servo#41209 Signed-off-by: tho <[email protected]>
follow up to #41209 #41209 does not read HTTP_PROXY (all caps) or `HtTp_PrOxY" or w/e. i personally have the variable in all caps. I propose we check both "HTTP_PROXY" and "http_proxy", but not mixed case. Firefox does just that at https://github.com/mozilla-firefox/firefox/blob/bef781bbd7a225c428c2444d7d02e9f6eb327e94/security/sandbox/chromium/base/environment.cc#L29-L42 --------- Signed-off-by: tho <[email protected]> Signed-off-by: Euclid Ye <[email protected]> Co-authored-by: Euclid Ye <[email protected]>
This parses the env variable "http_proxy" for servoshell and sets the network_http_proxy_uri if it exists to the same value.
Testing: Tested that it correctly picks it up.