Forum Moderators: phranque
Site I'm hosting is a subdomain, ie. subdomain.mydomain.com. I've created .crt and .key files, the ssl_error_log shows those are ok....
I've went through all the basic SSL How To's, and for some reason can't get it to serve an https page.
Do I have to use a Virtual Host directive? Here's what I have in my httpd.conf file :
#
# Use name-based virtual hosting.
#
NameVirtualHost 192.168.1.96:80
NameVirtualHost 192.168.1.96:443
<VirtualHost 192.168.1.96:443>
ServerName subdomain.mydomain.com
DocumentRoot /var/www/msg
ErrorLog /var/log/httpd/msg_error_log
CustomLog /var/log/httpd/msg_access_log common
DirectoryIndex index.php index.html
SSLEngine On
SSLCertificateFile /etc/pki/tls/certs/server.crt
SSLCertificateKeyFile /etc/pki/tls/private/server.key
<Directory "/var/www/msg">
Options Indexes FollowSymLinks Includes
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
<VirtualHost 192.168.1.96:80>
ServerName subdomain.mydomain.com
DocumentRoot /var/www/msg
ErrorLog /var/log/httpd/msg_error_log
CustomLog /var/log/httpd/msg_access_log common
DirectoryIndex index.html index.shtml
<Directory "/var/www/msg">
Options Indexes FollowSymLinks Includes
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
and in my ssl.conf file :
<VirtualHost _default_:443>
# General setup for the virtual host, inherited from global configuration
DocumentRoot "/var/www/msg"
ServerName subdomain.mydomain.com:443
# SSL Engine Switch:
# Enable/Disable SSL for this virtual host.
SSLEngine on
# Server Certificate:
SSLCertificateFile /etc/pki/tls/certs/server.crt
# Server Private Key:
SSLCertificateKeyFile /etc/pki/tls/private/server.key
Wondering how this config looks...again, not going to be running multiple sites on this server (yet), so looking for a basic setup. Thanks in advance!
BFC