0

I'm trying to setup my site through ssl. Apache starts without trouble but firefox gives me the following error:

'Unable to connect'.

My virtualhost config:

<VirtualHost _default_:443>
DocumentRoot /var/www/site
ServerName site.nl
ServerAlias www.site.nl
SSLEngine ON
SSLCertificateFile      /etc/letsencrypt/live/site.nl/cert.pem
SSLCertificateKeyFile   /etc/letsencrypt/live/site.nl/privkey.pem
</VirtualHost>


<VirtualHost *:80>
DocumentRoot /var/www/site
ServerName site.nl
ServerAlias www.site.nl
</VirtualHost>

ports.conf:

Listen 80 443

I'm in the beta of letsencrypt.org.

Running apache2 on Linux

I have tried about everything there is to find about this on google.

Note: it connects fine through http (without ssl, port 80)

  • 1) Can you telnet port 443 of your server from the machine from where you're connecting with firefox? 2) If the machine you're using firefox has linux, try this: openssl s_client -connect YOURSERVERHOSTNAME and check that it works, showing you the server pubblic cert, CN and such. – Fredi Nov 12 '15 at 0:42
  • Telnet tells me "connection refused". I am running Linux (both laptop and server) but the command with openssl just prints out the how to use stuff so I'll have to look into that more at least. – joostlinux Nov 12 '15 at 0:46
  • I bet you dont have mod_ssl loaded. Edit you have both ports in the same Listen directove? Try putting two lines: Listen 80 Listen 443 – Fredi Nov 12 '15 at 0:47
  • a2enmod ssl gives me: Module ssl already enabled. – joostlinux Nov 12 '15 at 0:50
  • I replied too fast, as for my edit, try putting two Listen lines, one for each of 80 and 443 – Fredi Nov 12 '15 at 0:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.