The "default" site is usles in in the ISPConfig 3

Discussion in 'Installation/Configuration' started by edi00, May 29, 2010.

  1. edi00

    edi00 Member

    The Ubuntu provides the "default" site folder in /etc/apache2/sites-available to be used as a template for other sites.

    However, if I add my "mod_perl2" configuration the ISPC3 will ignore such manual addition so I must manually add my changes to new site.

    Furthermore, if I want to update my site via the ISPC3 it will erase all my manual changes and ISPC3 will create its own default..... no good!

    Is there any way how to work around this problem?
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    No need to work around anything, you just changed the wrong files. For example the default site in ubuntu is just the default site, it is there if no specific vhost is created, it is not a template for any other site.

    Also never edit any vhost file manually. They are not made for manual edits. There are 2 easy methods for adding custom configuration for a vhost:

    a) Add your custom code in the apache directives field of the website.
    b) If a setting shall be changed for all new sites, then change the vhost template in /usr/local/ispconfig/server/conf/
  3. edi00

    edi00 Member

    Can you be little bit more specific?... please.

    I wan to make changes to all sites which I create..... which file should I modify "vhost.conf.master"?... and how?
    Lets say I want to add this:
    Alias  /perl/ /var/www/clients/client1/web4/perl/
    <Directory /var/www/clients/client1/web4/perl>
        Order allow,deny
        Allow from all
    # the /clients/client1/web4 are variable based on site.
    # and /perl should create directory 
    Also please show the apache directives used in the website in which file they should be used.
    Last edited: May 29, 2010
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    As I explained, there are two options.

    a) Post the code from your above post in the apache directives field. Thats all.

    or b) Modify the vhost.conf.master file and add it there. Instead of setting a fixed path /var/www/clients/client1/web4, use one of the placeholder variables, in this case:

    {tmpl_var name='document_root'}
  5. edi00

    edi00 Member

    Got the b) but unclear on a) The "apache directives field" where?... which file vhost?
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    no file. the apache directives field is on the options tab of the website settings in the ispconfig interface.

Share This Page