<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[iRedMail — Apache multiple virtual hosts]]></title>
	<link rel="self" href="http://www.iredmail.org/forum/feed-atom-topic4418.xml" />
	<updated>2013-01-29T16:07:37Z</updated>
	<generator>PunBB</generator>
	<id>http://www.iredmail.org/forum/topic4418-apache-multiple-virtual-hosts.html</id>
		<entry>
			<title type="html"><![CDATA[Re: Apache multiple virtual hosts]]></title>
			<link rel="alternate" href="http://www.iredmail.org/forum/post20105.html#p20105" />
			<content type="html"><![CDATA[<p>I managed to make some progress but now i can&#039;t access /phpmyadmin and /iredadmin.</p><p>This is what i got so far.</p><div class="codebox"><pre><code>&lt;VirtualHost *:80&gt;
    ServerName www.domain.com
    ServerAlias domain.com
    DocumentRoot /var/www/html
    Options -MultiViews +FollowSymlinks -Indexes
&lt;/VirtualHost&gt;

&lt;VirtualHost *:80&gt;
    ServerName mail.domain.com
    DocumentRoot /var/www/roundcubemail
    Options -MultiViews +FollowSymlinks -Indexes
&lt;/VirtualHost&gt;


&lt;VirtualHost *:443&gt;
   ServerName mail.domain.com
   DocumentRoot /var/www/roundcubemail

   &lt;Directory &quot;/var/www/roundcubemail&quot;&gt;
     Options -Indexes FollowSymlinks MultiViews
     AllowOverride All
     Order allow,deny
     Allow from all
   &lt;/Directory&gt;

   ErrorLog logs/ssl_error_mail1_log
   TransferLog logs/ssl_access_mail1_log
   LogLevel warn
   SSLEngine on
   SSLProtocol all -SSLv2
   SSLCipherSuite ALL:!ADH:!EXPORT:!SSLv2:RC4+RSA:+HIGH:+MEDIUM:+LOW
   SSLCertificateFile /etc/pki/tls/certs/iRedMail_CA.pem
   SSLCertificateKeyFile /etc/pki/tls/private/iRedMail.key

   &lt;Files ~ &quot;\.(cgi|shtml|phtml|php3?)$&quot;&gt;
      SSLOptions +StdEnvVars
   &lt;/Files&gt;

   &lt;Directory &quot;/var/www/cgi-bin&quot;&gt;
      SSLOptions +StdEnvVars
   &lt;/Directory&gt;

   setEnvIf User-Agent &quot;.*MSIE.*&quot; \
         nokeepalive ssl-unclean-shutdown \
         downgrade-1.0 force-response-1.0

   CustomLog logs/ssl_request_mail1_log \
          &quot;%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \&quot;%r\&quot; %b&quot;

&lt;/VirtualHost&gt;</code></pre></div><br /><br /><p>I finally managed to get it working for multiple domains. Just had to carefully separate general from targeted config found here<br /><a href="http://www.iredmail.org/forum/topic3907-iredmail-support-changing-iredmail-services-alias-to-virtual-hosts.html">http://www.iredmail.org/forum/topic3907 … hosts.html</a></p><p>Thank you digitalbit!</p>]]></content>
			<author>
				<name><![CDATA[marius.cdm]]></name>
				<uri>http://www.iredmail.org/forum/user32562.html</uri>
			</author>
			<updated>2013-01-29T16:07:37Z</updated>
			<id>http://www.iredmail.org/forum/post20105.html#p20105</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Apache multiple virtual hosts]]></title>
			<link rel="alternate" href="http://www.iredmail.org/forum/post20104.html#p20104" />
			<content type="html"><![CDATA[<p>==== Required information ====<br />- iRedMail version: iRedMail-0.8.3.tar.bz2<br />- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL<br />- Linux/BSD distribution name and version: CentOS 6.3<br />==== </p><p>Hey guys,</p><p>I&#039;m trying to achive 3 goals in my setup.</p><p>1. Disable /mail, /webmail, /roundcube for every new domain and subdomain<br />2. Redirect mail.example.com, mail.example1.com, mail.exampleX.com to where /mail was.<br />3. Redirect every domain and subdomain to it&#039;s related website. Not comon ofc.</p><p>My DNS records are up and running for the hosted domains, the question is what do i need to modify in Apache config to get it right?</p><p>I&#039;ve tryed different examples, no luck so far.</p><p>Thank you!</p>]]></content>
			<author>
				<name><![CDATA[marius.cdm]]></name>
				<uri>http://www.iredmail.org/forum/user32562.html</uri>
			</author>
			<updated>2013-01-29T14:46:22Z</updated>
			<id>http://www.iredmail.org/forum/post20104.html#p20104</id>
		</entry>
</feed>
