I’m setting up phpmyadmin and was following the directions in the Linode Library. All went fine until I set up the SSL service on my Linode.
I followed the directions adding a2enmod ssl and generating the certificate. I then went into ports.conf and added the following line:
NameVirtualHost 12.34.56.78:443 (using my own IP)
I wanted only to use phpmyadmin on the default site (I figured I could use the IP address to access it) and not on my domains.
So I went into sites-available and edited the configuration file for 'default'. I kept what was already there and added to the bottom of the file (changing the IP address of course).
Code:
<VirtualHost 12.34.56.78:443>
SSLEngine On
SSLCertificateFile /etc/apache2/ssl/apache.pem
SSLCertificateKeyFile /etc/apache2/ssl/apache.key
ServerAdmin info@mydomain.com
ServerName www.mydomain.com
DocumentRoot /var/www/
ErrorLog /var/log/apache2/error.log
CustomLog /var/log/apache2/access.log combined
</VirtualHost>
The problem is that my server now asks for SSL connections for all domains hosted on the server. If I try
www.mydomainname.com I get "You're speaking plain HTTP to an SSL-enabled server port."
If I disable ‘default’ I can see them properly without SSL but can’t use SSL on any of them (I get Error code: ssl_error_rx_record_too_long).
I only want to use SSL on 'default'. Is this possible?