I have CentOS 8 I installed LAMP, Varnish, etc.
I setup hosts
/etc/hosts
ip site1.com www.site1.com ip site2.com www.site2.com
I setup Apache like this:
/etc/httpd.conf to include sites-enabled/ I have sites-enabled and sites-available with two configurations, site1.com.conf and site2.com.conf
Here what I included in etc/httpd/conf/httpd.conf
IncludeOptional sites-enabled/*.conf
Still it is not working. Any idea how to fix this?
I have sites-enabled and sites-available with this *.conf:
<VirtualHost *:8080>
ServerName ip
Redirect / 301 external_site
</VirtualHost>
and
<VirtualHost *:8080>
ServerName site2.com
ServerAlias www.site2.com
DocumentRoot /var/www/site2.com/html
ErrorLog /var/www/site2.com/html/log/error.log
CustomLog /var/www/site2.com/html/log/requests.log combined
</VirtualHost>
I manage to get this to work now but the https versions are not working, how to fix the https versions ?
I generate 2 ceritficates using mod_ssl
I put 1 of them in /etc/httpd/conf.d/httpd.conf ...
Fixed: Problem was misconfiguration of /etc/httpd/conf.d/ssl.conf
0 Answers