Hello and thank you for reading.
I have a windows 2016 server running apache.
I am attempting to have a virtual host set up on one port (8080) and
have it automatically forward any and everything it sees to the main Apache host
(The not virtual instance? I’m unclear of the correct term to call it)
which lives on port 80
My configuration is below.
I show that the server is listening on both port 80 and 8080.
When I go to port 80. I get the default "It works" page
When I go to port 8080
I get the following error:
Internal Server Error
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator at [email protected] to inform them of the time this error occurred, and the actions you performed just before this error.
More information about this error may be available in the server error log.
I consult the log and I see the following message
[Thu Sep 24 07:29:16.128967 2020] [proxy:warn] [pid 4860:tid 1076] [client 192.168.50.160:64768] AH01144: No protocol handler was valid for the URL / (scheme ‘https’). If you are using a DSO version of mod_proxy, make sure the proxy submodules are included in the configuration using LoadModule.
I am attempting to do this without any ssl/or encrypption
A copy of my configuration and loaded modules is listed below.
I have included only the parts of the base conf file that have been modified
What am I missing, or what should i try next to fix?
Thank you community.
2
Answers
It sounds like you’re connecting to 192.168.50.160:8080 using
https
, nothttp
. If you want to use HTTPS, you’ll need to set up your :8080 VirtualHost to support it properly.https://www.digitalocean.com/community/tutorials/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-16-04
You’re encountering an issue as your SSL is not configured, and you’re trying to go through HTTPS, as Eliezer stated you need to create your key, to do so I use LetsEncrypt (certbot) but the choice is up to you, (and I’m on Ubuntu)
Your ports.conf file should have some lines that look like this like this:
You also need to add
<VirtualHost *:443> Your configuration inside the tags</VirtualHost>
tag in your conf after adding it to the listened portAnd then your conf file, you need to enable SSL :
I would also advise to force redirection on https, once your SSL is configured with a rewrite rule:
This answer is base for an Apache Ubuntu config, but I think can you work from it to your Windows Server Apache config