refactor proxy handling code (#2357)

- allow gallery-dl proxy settings to overwrite environment proxies
- allow specifying different proxies for data extraction and download
  - add 'downloader.proxy' option
  - '-o extractor.proxy=–PROXY_URL -o downloader.proxy=null'
    now has the same effect as youtube-dl's '--geo-verification-proxy'
This commit is contained in:
Mike Fährmann
2022-03-10 23:32:16 +01:00
parent d50a1ec2cc
commit 47cf05c4ab
8 changed files with 52 additions and 23 deletions

View File

@@ -477,6 +477,7 @@ Description
| Can be either a simple ``string`` with just the local IP address
| or a ``list`` with IP and explicit port number as elements.
extractor.*.user-agent
----------------------
Type
@@ -2619,6 +2620,17 @@ Description
Certificate validation during file downloads.
downloader.*.proxy
------------------
Type
``string`` or ``object``
Default
`extractor.*.proxy`_
Description
| Proxy server used for file downloads.
| Disable the use of a proxy by explicitly setting this option to ``null``.
downloader.http.adjust-extensions
---------------------------------
Type