everywall / ladder

Selfhosted alternative to 12ft.io. and 1ft.io bypass paywalls with a proxy ladder and remove CORS headers from any URL
GNU General Public License v3.0
4.29k stars 169 forks source link

HTTP Timeout #64

Closed lutfuahmet closed 6 months ago

lutfuahmet commented 6 months ago

This pull request introduces a configurable timeout feature for http client. The default timeout is set to 15 seconds, but users can now modify it by utilizing the HTTP_TIMEOUT environment variable.

dxbednarczyk commented 6 months ago

@mms-gianni this PR ignores the error from strconv.Atoi, if the environment variable is set to "15s" instead of just "15", the variable won't do anything. For invalid values we should warn the user that it would be ignored.