1. My Caddy version (caddy version
):
v2.0.0.0-beta.15 (windows)
2. How I run Caddy:
i will start it with task scheduler to run on system boot but for now just running form command line
a. System environment:
Windows Server 2012 r2
b. Command:
caddy reverse-proxy --from test.com --to localhost:1022
c. Service/unit/compose file:
Binary install not docker
d. My complete Caddyfile or JSON config:
http://localhost:2015
{
redir https://{hostonly}{uri}
}
3. The problem I’m having:
i have a few problems, but this is what i want to do, i have a web application running on the localhost on port 1022.
I want to redirect users the connect to that address test.com:1022 to a HTTPS address such as https://test.com.
The localhost is using port 80 so cant bind to it, i have tryed to change the default port 80 to an other port using -http-port but have failed.
I can port forward on the public internet facing firewall port 80 and 443 to any port on the localhost.
4. Error messages and/or full log output:
reverse-proxy: loading new config: http app module: start: tcp: listening on :80
: listen tcp :80: bind: An attempt was made to access a socket in a way forbidden by its access permissions.
5. What I already tried:
I have tried verious combinations of putting -http-port 4030 in the caddy file and onthe commandline but to no avale, i think i am missing a basic understanding of how to use Caddy but i cant see it for looking.