The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Add virtualhost to httpd.conf

Discussion in 'General Discussion' started by tomtiger11, Jul 10, 2012.

  1. tomtiger11

    tomtiger11 Registered

    Joined:
    Feb 19, 2011
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    I need to add a virtualhost to httpd.conf, but when i add it, the distiller goes through with the operation, then i rebuild, and my change is gone!
     
  2. Brian

    Brian Well-Known Member

    Joined:
    Dec 1, 2010
    Messages:
    117
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Texas
    cPanel Access Level:
    Root Administrator
    The distiller is for distilling changes to existing configurations that cPanel & WHM itself creates and maintains. If you want to add a new VirtualHost altogether, the distiller can't help you there.

    To add a brand new VirtualHost, your best bet is going to be to add it to either the pre-VirtualHost include file or post-VirtualHost include file. This will place your VirtualHost entry either before all of cPanel's generated VirtualHosts or after all of cPanel's generates VirtualHosts respectively.

    The include files can be edited via:

    WHM -> Apache Configuration -> Include Editor

    They're located at /usr/local/apache/conf/includes/ if you'd rather modify them directly.
     
  3. tomtiger11

    tomtiger11 Registered

    Joined:
    Feb 19, 2011
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Nope, Didnt work :/
     
  4. cPanelTristan

    cPanelTristan Quality Assurance Analyst
    Staff Member

    Joined:
    Oct 2, 2010
    Messages:
    7,623
    Likes Received:
    21
    Trophy Points:
    38
    Location:
    somewhere over the rainbow
    cPanel Access Level:
    Root Administrator
    What are you trying to add specifically? Please provide what is being added and the purpose of what is being added, so we know what you are attempting to do.
     
Loading...

Share This Page