apache2 - Setting up ssl certificate on apache server with virtual hosts -


i'm trying set digicert ssl wildcard certificate apache server. i'm bit confuse something. have following config far:

namevirtualhost *:80 <virtualhost *:80>   servername x.y.com   serveralias x.y.com   documentroot /webapps/x/public   <directory /webapps/x/public>     options -multiviews     order deny,allow     allow   </directory>   errorlog /var/log/apache2/y.com_error.log   loglevel warn   customlog /var/log/apache2/y.com_access.log combined   serversignature on </virtualhost>  namevirtualhost *:443 <virtualhost *:443>   servername x.y.com   serveralias x.y.com   documentroot /webapps/x/public   <directory /webapps/x/public>     options -multiviews     order deny,allow     allow   </directory>   errorlog /var/log/apache2/y.com_error.log   loglevel warn   customlog /var/log/apache2/y.com_access.log combined   serversignature on    sslengine on   sslcertificatefile /etc/certificates/www_y_com.crt   sslcertificatekeyfile /etc/certificates/www_y_com.key   sslcertificatechainfile /etc/certificates/digicertca.crt   railsenv myenv </virtualhost> 

but get:

namevirtualhost *:80 has no virtualhosts (98)address in use: make_sock: not bind address 0.0.0.0:443 no listening sockets available, shutting down

how should configure in order make work?

thanks lot!

at glance virtual host xml looks correct. write namevirtualhost directive in ports.conf file , each virtual host must have own file. on system located @ /etc/apache2/sites-available/your-domain-name

one more thing. make sure port 443 open in router. forget time , spend hours trying figure out when simple port forwarding 443 server ip within router config.

also don't forget enable site.

# enable site sudo a2ensite  # disable site sudo a2dissite 

Comments

Popular posts from this blog

How to mention the localhost in android -

php - Calling a template part from a post -

c# - String.format() DateTime With Arabic culture -