Where best to put Apache directives?

Discussion in 'General' started by crypted, Mar 11, 2011.

  1. crypted

    crypted New Member

    Allright, I'm setting up mod_spamhaus and mod_slotlimit as per HOWTO's on this site. Each require "IfModule" code but the instructions say to put it in /etc/apache2/apache2.conf.

    I'm thinking it would be better to put mod_spamhaus in ISPC's interface under Apache Directives possibly. Can I have custom IFMODULES per website in the directives? That way spamhaus wouldn't be used on smaller websites.
    Code:
    <IfModule mod_spamhaus.c>
    MS_METHODS POST,PUT,OPTIONS,CONNECT
    MS_WhiteList /etc/spamhaus.wl
    MS_CacheSize 256
    </IfModule>
    
    Mod_slotlimit requires the following to be in the apache2.conf. Is it wise to put it in there? Or, does ISPC need it to be elsewhere? This is a global setting.
    Code:
    <IfModule mod_slotlimit.c>
    AvailableSlotsPercent 15
    MaxConnectionsPerSite 30
    LimitSite www.BadSite.xxx
    LimitSiteConnections 15
    ClientIpLimit 15
    ForceVhostName On
    </IfModule>
    
     
  2. falko

    falko Super Moderator ISPConfig Developer

    I *think* you can put this in virtual hosts as well, but I haven't tried.

    Yes, you can put it in the apache2.conf if this should be a global setting.
     

Share This Page