Closed monkey-jsun closed 9 months ago
For the first point, you should refer to the official Caddy documentation and inquire in the Caddy community. Regarding the second point, you can refer to other relevant issues, such as https://github.com/klzgrad/naiveproxy/issues/587.
Thanks for the pointer. Do you know why the official Caddy document looks similar but not exactly the same? For example, in your example we use "basic_auth", but in the official Caddyfile document it uses "basicauth", which supports multiple users.
There are others that also fall into this strange "similar but different" category, such as forward_proxy vs forwardproxy.
Yes, because Caddy has two versions.
To be compatible with Caddy 2, the latest forwardproxy (caddy2 branch) indeed uses the forward_proxy
and basic_auth
directives, whereas the previous version (master branch) used forwardproxy
and basicauth
directives.
Multiple auth is fixed here https://github.com/klzgrad/forwardproxy/releases/tag/v2.7.6-naive
I followed the readme.md file and got everything up and running. Great! Thanks!
I like to venture to tweak a couple of things, but I'm having troubles.
The first challenge is to use alternative http/https ports(8080/8443). I added the following directives to the Caddyfile and caddy starts up fine with the designated high ports. However, when I open URL at http://:8080, the browser redirects to https://:443, instead of https://:8443. How do I achieve this?
My second challenge is to add multiple user accounts. How do I do that?
BTW, I googled Caddyfile format and it seems quite different from what is used here. For example, forward_proxy would become forwardproxy, and basic_auth becomes basicauth. I'm quite lost.