Current time: 11-23-2024, 07:27 AM Hello There, Guest! (LoginRegister)


Post Reply 
[SOLVED] Apache: Sites Enabled: 00_master.conf
Author Message
HSorgYves Offline
Junior Member
*

Posts: 94
Joined: Feb 2008
Reputation: 0
Post: #1
[SOLVED] Apache: Sites Enabled: 00_master.conf
Dear,

My settings are:
ispCP running under ispCP.tld while tld is my main domain which also has http://www.tld and is managed by ispCP.

As far as I understood, ispCP.tld is loaded by 00_master.conf while http://www.tld is by ispcp.conf. This means that when accessing the server via IP, then ispCP.tld will be displayed.

Now my question:
Is there any harm in changing the link to master.conf, which would mean that the file would be loaded after ispcp.conf?

Thanks,
Yves
(This post was last modified: 05-03-2008 07:20 AM by HSorgYves.)
04-19-2008 05:16 AM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #2
RE: Apache: Sites Enabled: 00_master.conf
try it.
04-19-2008 07:51 AM
Visit this user's website Find all posts by this user Quote this message in a reply
HSorgYves Offline
Junior Member
*

Posts: 94
Joined: Feb 2008
Reputation: 0
Post: #3
RE: Apache: Sites Enabled: 00_master.conf
Doesn't work... :-(
04-20-2008 01:29 AM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #4
RE: Apache: Sites Enabled: 00_master.conf
So the answer is "no" :-)))

If you don't wnat to have the ispcp site to be the default site, just write a onw vhost block in the 00_master - before! the ispcp...

check with
apache2 -S
this will tell you which is the default vhost setting...
04-20-2008 03:19 AM
Visit this user's website Find all posts by this user Quote this message in a reply
HSorgYves Offline
Junior Member
*

Posts: 94
Joined: Feb 2008
Reputation: 0
Post: #5
RE: Apache: Sites Enabled: 00_master.conf
I have been thinking to add a 00_default.conf; the result would be the same. But am I allowed to add the same vhost block in 00_default.conf/00_master.conf that is already present in ispcp.conf?

Thanks,
Yves
04-20-2008 07:56 AM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #6
RE: Apache: Sites Enabled: 00_master.conf
no, you should not add the same.

But if you want one domain of ispcp.conf to be the default domain, add this block except for the lines ServerName and ServerAlias. Put only the line
ServerName 123.45.67.89
(your IP) instead of the two...

If this is loaded as first vhost then I think it's the default vhost... and points to the domain you want

/J
04-20-2008 09:15 AM
Visit this user's website Find all posts by this user Quote this message in a reply
HSorgYves Offline
Junior Member
*

Posts: 94
Joined: Feb 2008
Reputation: 0
Post: #7
RE: Apache: Sites Enabled: 00_master.conf
Thanks,

Working fine this way.

What about the first lines in ispcp.conf? Should I add them to 00_default.conf as well?
Code:
#
# wget-hack prevention
#

<IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteCond %{HTTP_USER_AGENT} ^LWP::Simple
    RewriteRule ^/.* http://%{REMOTE_ADDR}/ [L,E=nolog:1]
</IfModule>

#
# Web traffic accounting.
#

LogFormat "%B" traff

#
# mod_cband configuration
#

<IfModule mod_cband.c>
    CBandScoreFlushPeriod 10
    CBandRandomPulse On
</IfModule>

#
# let the customer decide what charset he likes to use
#

AddDefaultCharset Off
And the traffic limit lines?
Code:
<IfModule mod_cband.c>
    <CBandUser domain.tld>
        # CBandUserLimit 0Mi
        # CBandUserScoreboard /var/www/scoreboards/domain.tld
        # CBandUserPeriod 4W
        # CBandUserPeriodSlice 1W
        # CBandUserExceededURL http://ispcp.domain.tld/errors/bw_exceeded.html
    </CBandUser>
</IfModule>
04-20-2008 08:05 PM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #8
RE: Apache: Sites Enabled: 00_master.conf
no - I think it's ok if they are there once.

You could move your vhost block from 00_default to 00_master (before the master-vhost-block)...

/J
04-20-2008 08:24 PM
Visit this user's website Find all posts by this user Quote this message in a reply
HSorgYves Offline
Junior Member
*

Posts: 94
Joined: Feb 2008
Reputation: 0
Post: #9
RE: Apache: Sites Enabled: 00_master.conf
Yes that's true; but I prefer to keep things clear. 00_master is an ispCP file while 00_default is my own configuration to set the default domains.

Some more information for others trying the same:
You can set all IPs in one VirtualHost Block, simply use
Code:
<VirtualHost xxx.xxx.xxx.xxx:80 yyy.yyy.yyy.yyy:80>
...
ServerName xxx.xxx.xxx.xxx
ServerAlias yyy.yyy.yyy.yyy
...
</VirtualHost>

Best Regards,
Yves
04-21-2008 02:27 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)