External Apache Directives

Discussion in 'General' started by vaio1, Oct 29, 2009.

  1. vaio1

    vaio1 Member

    Hi Falko and Till,

    I'm trying to add some items inside the Apache directives but when I try to save the site details page the text is truncated.

    I admit that I have paste about 3000 rows inside it because we have a customer with thousands of domains that redirect only in one site. So I thought to ask you if there is a way to create an external file to attach to the apache directives.

    Is it possible?

    These are only two domains that I redirect to the main php controller folder:
    Code:
    RewriteCond %{HTTP_HOST} [a-z]\.website1000\.[a-z]+$ [NC]
    RewriteRule ^/(.*)         http://www.website1000.com/public/$1 [L]
    
    RewriteCond %{HTTP_HOST} [a-z]\.website1001\.[a-z]+$ [NC]
    RewriteRule ^/(.*)         http://www.website1001.com/public/$1 [L]
    
    thanks for your precious help.
     
    Last edited: Oct 29, 2009
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    You can use the apache include directive in the apache directives field to include a external file in into the vhost configuration.
     
  3. vaio1

    vaio1 Member

    Is it correct?

    Include /var/www/web1/web/my.conf
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes, should work like that.
     
  5. vaio1

    vaio1 Member

    Have I restart the apache?
     
  6. vaio1

    vaio1 Member

    I have tested your suggestions but I have discovered that the modification of the Apache Directive doesn't copied in the /etc/httpd/conf/vhosts/Vhosts_ispconfig.conf

    What I have do:
    I have opened the /etc/httpd/conf/vhosts/Vhosts_ispconfig.conf file
    then I insert the Include row and I save the file
    I have rebooted the apache service and it has worked good

    Now I have deleted the Include from the administration Apache Directive page of the customer website and the Include row is disappeared from the /etc/httpd/conf/vhosts/Vhosts_ispconfig.conf

    can u help me please? Seems that the Apache Directive doesn't accept the Include directive.
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

  8. vaio1

    vaio1 Member

    What do you mean?! I have read it but it doesn't solve the problem.
     
  9. vaio1

    vaio1 Member

  10. till

    till Super Moderator Staff Member ISPConfig Developer

    Thats not the case. I use it for several sites.

    You posted above that your httpd.conf file does not get written, so please do what I described in the other thread that I linked above to find the problem in your httpd.conf.
     

Share This Page