ATutor

Learning Management Tools







Pages:1 2 3 4 5 6 7 8 9 10 11 12 13 14 15


Setting Atutor behind a Reverse Proxy


  • 2010-07-02 10:21:26

    Setting Atutor behind a Reverse Proxy

    People from internet are not able to login to my Atutor
    while from LAN any one can login and it works fine.



    Things to describe:
    Operating system ATutor is installed on - Ubuntu 10.04
    ATutor version - 1.6.4
    Patch #s applied - none
    ATutor theme name - no idea what that means
    PHP version - 5
    MySQL version - Ver 14.14 Distrib 5.1.41, for debian-linux-gnu (x86_64) using readline 6.1

    Webserver & version - Apache 2
    Copies of error messages - None
    Changes to default settings - Nome
    Web browser being used - Chrome,Firefox 3
    ...and anything else relevant -

    I am testing ATutor on our LAN it installed and worked fine.We now want it to be publicly accessible we have some websites running on our webserver in a Reverse Proxy environment.

    I configured the same for ATutor but the page being served to client browser on internet was not able to login to the Atutor interface we have.

    I want to know how does ATutor handles X-Forwarded-For header when a request comes to it forwarded via Reverse Proxy where can I give it the IP of my Reverse Proxy Server so that it can maintain the session or the user can login the
    Settings of Reverse Proxy on Apache2 for Atutor are
    <VirtualHost *:80>

    ServerAdmin webmaster@localhost
    ServerName mydomain.com
    ProxyRequests off


    ProxyRequests off
    <Proxy *>
    Order deny,allow
    Allow from all
    </Proxy>

    ProxyPass /atutor http://192.168.1.5/atutor
    ProxyPassReverse /atutor http://192.168.1.5/atutor
    </VirtualHost

  • 2010-07-02 14:59:51

    Re: Setting Atutor behind a Reverse Proxy

    Have a look at the setting "ProxyPreserveHost On" first. If that doesn't
    work, ProxyPassReverseCookieDomain and ProxyPassReverseCookiePath are
    two more directives to try.

    http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#proxypassreverse
    shows an example with the latter two options.

  • 2010-07-05 02:19:26

    Re: Setting Atutor behind a Reverse Proxy

    I have 7-8 websites
    running on the said server

    <VirtualHost *:80>

    ServerAdmin webmaster@localhost
    ServerName mydomain.com
    ProxyRequests off
    <Proxy *>
    Order deny,allow
    Allow from all
    </Proxy>

    ProxyPreserveHost On

    ProxyPass /something1 http://192.168.1.5/something1
    ProxyPassReverse /something1 http://192.168.1.5/something1

    ProxyPass /something2 http://192.168.1.5/something2/www/
    ProxyPassReverse /something2 http://192.168.1.5/something2/www/

    ProxyPass /something3 http://192.168.1.5/something3/
    ProxyPassReverse /something3 http://192.168.1.5/something3/

    ProxyPass /something4 http://192.168.1.5/something4/
    ProxyPassReverse /something4 http://192.168.1.5/something4/

    ProxyPass /something5 http://192.168.1.5/something5
    ProxyPassReverse /something5 http://192.168.1.5/something5

    ProxyPass /something6 http://192.168.1.5:8080/something6
    ProxyPassReverse /something6 http://192.168.1.5:8080/something6

    ProxyPass /something7 http://192.168.1.5:6060/portal
    ProxyPassReverse /something7 http://192.168.1.5:6060/something7

    ProxyPass /atutor http://192.168.1.5atutor
    ProxyPassReverse /atutor http://192.168.1.5atutor
    ProxyPassReverseCookieDomain internal.domain.com external.domain.com
    ProxyPassReverseCookiePath / /atutor







    ProxyPass / http://192.168.1.5/
    ProxyPassReverse / http://192.168.1.5/

    ErrorLog /var/log/apache2/mydomain_error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel debug

    CustomLog /var/log/apache2/mydomain_access.log combined

    CustomLog /var/log/apache2/mydomain-resp_log resp
    LogFormat "%D %{X-Forwarded-For}i %t" resp

    </VirtualHost>

    It did not worked can you point what is the mistake above

  • 2010-07-05 09:47:17

    Re: Setting Atutor behind a Reverse Proxy

    You might be better off talking to someone from Apache. This is a little outside the scope of the kind of support we can offer.

  • 2010-07-07 05:15:27

    Re: Setting Atutor behind a Reverse Proxy

    Thanks for the update but when using an application behind a reverse proxy X-Forwarded-For is the header used for which I started the question originally as how is this header handled in Atutor.