1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice

conf, skel, and subdomains

Discussion in 'Plesk for Linux - 8.x and Older' started by ArchStanton, Dec 23, 2005.

  1. ArchStanton

    ArchStanton Guest

    0
     
    How to create a vhost.conf file in the skel directory for subdomains?

    I'm creating a bunch of subdomains that I would like to be able to include php files from the parent domain. Of course open_basedir restriction is a problem. I am going to try using the skeletons to add a conf directory with a vhost.conf file to overcome this problem. Will the skel files work with the subdomains?

    Does the @domain_name@ refer to the parent domain, or the subdomain? How would I create a conf file that would accomplish the following:

    Code:
    
    <Directory  /home/httpd/vhosts/domain.com/subdomains/sub_name/httpdocs>
    
            php_admin_value open_basedir "/home/httpd/vhosts/domain.com/httpdocs:/home/httpd/vhosts/domain.com/subdomains/sub_name/httpdocs:/tmp"
    
    </Directory>
    
    
    The following obviously would not work, but does anyone know something similar to this that would?

    Code:
    
    <Directory  /home/httpd/vhosts/@domain_name@/subdomains/@sub_domain_name@/httpdocs>
    
            php_admin_value open_basedir "/home/httpd/vhosts/@domain_name@/httpdocs:/home/httpd/vhosts/@domain_name@/subdomains/@sub_domain_name@/httpdocs:/tmp"
    
    </Directory>
    
    
     
  2. ArchStanton

    ArchStanton Guest

    0
     
    Another thought. Somewhere is the template or script used to create the httpd.include files for each domain. Is there any way to edit these?
     
  3. ArchStanton

    ArchStanton Guest

    0
     
  4. ArchStanton

    ArchStanton Guest

    0
     
    Any help here would be appreciated.
     
  5. ArchStanton

    ArchStanton Guest

    0
     
    Does anyone even have a clue if I'm on the right track?
     
  6. ArchStanton

    ArchStanton Guest

    0
     
    Is there anybody out there?
     
  7. Charles Coleman

    Charles Coleman Guest

    0
     
    Did you find and answer to this question yet? I am interested in exactly how I can use the skel directory. I thought I read somewhere that the conf directory would be removed automatically for security reasons but someone would have to confirm this for this to be a legitimate comment ;)
     
  8. ArchStanton

    ArchStanton Guest

    0
     
    Never got an answer from anyone on this. I eventually gave up.

    My solution, which may or may not help anyone, much like this forum, was this: instead of trying to include the files from another directory, I used PHP's FTP functions to transfer the files from the server to itself. The owners of the site can run the script whenever they create a new sub-domain. I also have the script create symbolit links to files that don't need to be executed, like images and css.

    If you think this might be helpful to you, I can dig up some example code.
     
  9. Charles Coleman

    Charles Coleman Guest

    0
     
    Hey, check out this thread thread... I'm sure you already know about this but you may not have thought of doing it quite this way.
     
Loading...