Forums | Mahara Community
Mahara/Moodle integration
/
Mahara/Moodle, virtual hosts, SSL, DocumentRoot, hacking
22 December 2010, 20:15
Happy holidays everyone,
I am setting up a new Moodle 2.0 / Mahara 1.3 environment. I have a few questions, and I am hoping that some sys admins more technical than I am can offer some insight. Here are the setup details / requirements:
- Ubuntu 10.04 Server
- Moodle directory is /var/www/moodle
- Mahara directory is /var/www/mahara/htdocs
- Authentication through Moodle with MNet access to Mahara
- No direct Mahara login (http://mahara.org/interaction/forum/topic.php?id=2010)
- SSL, either logon-only or complete, depending on requirements that are currently unknown
- Only 1 IP address is available on the server (sucky Amazon EC2 limitation)
- DNS A record will associate http://something.company.com with the server IP
- Typing something.company.com in the browser will take people to the Moodle home page
Both Moodle and Mahara are installed and SSO is configured. So far so good. However, I have questions about the best way to finish the configuration:
- If I make /var/www/moodle my DocumentRoot in Apache, I can’t get to Mahara without using virtual hosts
- Because I am limited to one IP address, I would have to use named-based virtual hosts on a single IP (http://httpd.apache.org/docs/2.0/vhosts/examples.html)
- This appears to be a problem with SSL (http://httpd.apache.org/docs/2.0/ssl/ssl_faq.html#vhosts)
There are two things I thought of, but they seem a bit hacky:
- No virtual hosts, Apache DocumentRoot /var/www, use a php 301 redirect in /var/www/index.php to http://something.company.com/moodle
- No virtual hosts, Apache Documentroot /var/www/moodle, install Mahara in the Moodle directory - /var/www/moodle/mahara
Any thoughts? Hacky is my middle name, but before I get out the machete, I want to make sure I am not overlooking something that will come back to bite me.
Thanks,
Ben
23 December 2010, 1:50
Can't you use the apache Alias and Directory directives to make /mahara point to your mahara root? Web folders don't have to be under the document root.23 December 2010, 6:18
I knew I was overlooking something obvious (to others)! Thanks Gregor. Setting DocumentRoot to /var/www/moodle and using alias and directory to get to mahara should work well. Ben