Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Tue May 01, 2012 4:40 pm 
Offline
Junior Member

Joined: Sun Dec 30, 2007 3:11 pm
Posts: 30
Website: http://www.triptoy.net
OK.

I have two IP addresses and a bunch of domains. One domain I'm going to be using for ecommerce with SSL and is my primary domain. I want this domain to have its own unique IP address.

I have about 7 other domains that I want to share the same secondary IP address.

I've tried a few things but botched the whole thing. I've reverted everything back to the standard way of doing things.

On Ubuntu 11 here.

Code:
<VirtualHost *:80>

        ServerAdmin admin@domain1.com
        ServerName domain1.com
        ServerAlias www.domain1.com
        DocumentRoot /var/www/domain1.com


        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>
        <Directory /var/www/domain1.com>
                Options Indexes FollowSymLinks MultiViews
                AllowOverride None
                Order allow,deny
                allow from all
        </Directory>

        ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
        <Directory "/usr/lib/cgi-bin">
                AllowOverride None
                Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
                Order allow,deny
                Allow from all
        </Directory>


That's what my current setup looks like for every site. I haven't set up the second IP on my server yet either.


Top
   
 Post subject:
PostPosted: Tue May 01, 2012 5:30 pm 
Offline
Junior Member

Joined: Sat Feb 18, 2012 12:26 pm
Posts: 24
Did you try something like this?

# ssl ip address
Listen 1.2.3.4:443
# other domains ip address
Listen 5.6.7.8:80

NameVirtualHost 1.2.3.4:443
NameVirtualHost 5.6.7.8:80

<VirtualHost 1.2.3.4:443>
ServerName ssl_domain
SSLEngine on etc
</VirtualHost>

<VirtualHost 5.6.7.8:80>
ServerName first_domain
</VirtualHost>

<VirtualHost 5.6.7.8:80>
ServerName second_domain
</VirtualHost>
etc

If you wanted the SSL site to also be on port 80, you'd have to add another Listen, NameVirtualHost and VirtualHost tag for 1.2.3.4:80


Top
   
 Post subject:
PostPosted: Tue May 01, 2012 6:00 pm 
Offline
Junior Member

Joined: Sun Dec 30, 2007 3:11 pm
Posts: 30
Website: http://www.triptoy.net
Where do I put:

Code:
# ssl ip address
Listen 1.2.3.4:443
# other domains ip address
Listen 5.6.7.8:80

NameVirtualHost 1.2.3.4:443
NameVirtualHost 5.6.7.8:80


?

I have all my configs for each site in sites-available and sites-enabled.

Code:
ls /etc/apache2/sites-enabled
domain1.com
domain1.net
domain2.com
domain2.net
domain3.com
domain3.net
domain4.com
domain4.net
domain4.org


Top
   
 Post subject:
PostPosted: Tue May 01, 2012 7:06 pm 
Offline
Junior Member

Joined: Sat Feb 18, 2012 12:26 pm
Posts: 24
listen and namevirtualhost go in the ports.conf file in/etc/apache2


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group