Need help on Lighttpd Virtual Host Config

Discussion in 'Site & Server Administration' started by thetechtalk, Sep 27, 2013.

  1. #1
    Recently i purchased a vps and want to use it as cdn.

    I wanted to point sub-domains such as

    cdn.website1.com
    cdn.website2.com
    cdn.website3.com
    to my vps dedicated ip and create folders such as

    /var/www/cdn.website1.com/
    /var/www/cdn.website2.com/
    /var/www/cdn.website3.com/
    so cdn.website1.com will display content from /var/www/cdn.website1.com/ and so on

    I installed lighttpd and enabled vhost using command lighttpd-enable-mod simple-vhost

    and editted /etc/lighttpd/conf-available/10-simple-vhost.conf

    to

    simple-vhost.server-root = "/var"
    simple-vhost.document-root = "www"

    But when i access cdn.website2.com it still points to content at var/www/ and not from /var/www/cdn.website1.com/
     
    thetechtalk, Sep 27, 2013 IP
  2. ryan_uk

    ryan_uk Illustrious Member

    Messages:
    3,983
    Likes Received:
    1,022
    Best Answers:
    33
    Trophy Points:
    465
    #2
    ryan_uk, Sep 28, 2013 IP