All pastes #899129 Raw Edit

Mine

public text v1 · immutable
·published 2008-02-10 22:13 UTC
rendered paste body
Summary
-------

I use SysCP to manage my virtual hosts but it doesn't do SSL.  I have however told SysCP that I want to use 443, but thats about as far as it goes - but it does explain why the following syscp_vhosts.conf file mentions 443.  I have made ssl_vhosts.conf myself and included it after the other include for syscp in httpd.conf.  Obviously the SSL certificate exists and I know it works, as you see I have turned the SSLEngine to ON.

Basically I want firstsite to be accessible on normal HTTP and also HTTPS, and secondsite to be only HTTP.

At the moment whether I browse to either of them on SSL (altho I only want firstsite on SSL) I get 'ssl_error_rx_record_too_long' or data connection interrupted on Firefox.

Note I'm running on Debian 4.0 Etch is this makes any difference.

httpd.conf
----------

DocumentRoot /var/www/
<Directory />
   Options FollowSymLinks
   AllowOverride None
</Directory>
<Directory /var/www/>
   Options FollowSymLinks MultiViews
   AllowOverride None
   Order allow,deny
   allow from all
</Directory>

Include /etc/apache2/syscp_vhosts.conf
Include /etc/apache2/ssl_vhosts.conf

syscp_vhosts.conf
-----------------

Listen 12.34.56.78:80
NameVirtualHost 12.34.56.78:80
<VirtualHost 12.34.56.78:80>
</VirtualHost>

Listen 12.34.56.78:443
NameVirtualHost 12.34.56.78:443
<VirtualHost 12.34.56.78:443>
</VirtualHost>

<VirtualHost 12.34.56.78:80>
  ServerName firstsite.com
  ServerAlias www.firstsite.com
  ServerAdmin person@firstsite.com
  DocumentRoot /mnt/Sites/firstsite.com/
</VirtualHost>

<VirtualHost 12.34.56.78:80>
  ServerName secondsite.com
  ServerAlias www.secondsite.com
  ServerAdmin person@secondsite.com
  DocumentRoot /mnt/Sites/secondsite.com/
</VirtualHost>

ssl_vhosts.conf
---------------

<VirtualHost 12.34.56.78:443>
  ServerName firstsite.com
  ServerAlias www.firstsite.com
  ServerAdmin person@firstsite.com
  DocumentRoot /mnt/Sites/firstsite.com/
</VirtualHost>