Difference between revisions of "MythWeb SVN Ubuntu"
(→Debian, Ubuntu (Apache 2): file locations) |
|||
Line 71: | Line 71: | ||
and go find test.php with your web-browser. clicking on it now should bring up a webpage congratulations you just enabled php in your apache webserver. | and go find test.php with your web-browser. clicking on it now should bring up a webpage congratulations you just enabled php in your apache webserver. | ||
− | brief discussion | + | == brief discussion == |
− | + | ||
+ | Debian decided this was an easy way to configure apache, in principle all modules exist within mods-available and all enabled mods will have a link in mods-enabled that points to the corresponding module in mods-available | ||
so if there are other modules you need it seems in principle you need to install with synaptic and then once the module is in mods-available create a link to it in mods-enabled. | so if there are other modules you need it seems in principle you need to install with synaptic and then once the module is in mods-available create a link to it in mods-enabled. |
Revision as of 12:54, 12 January 2008
Contents
installing and configuring mythweb from svn
Ok if your here, you should have built mythtv mythtvplugins and mythtvthemes and mythtv itself should be working however now you are tearing your hair out because you cannot get mythweb working. Your also running a version of ubuntu, hopefully thats gutsy but if it isn't this little guide should still apply.
Apache Configuration
first problem i had was with php its not enabled on apache2 by default if thats not working mythweb isn't going to work.
To test if php5 installed correctly
sudo gedit /var/www/test.php
Insert the following line into the new file
<?php phpinfo();?>
and save it
now lets test it, if your working locally then 127.0.0.1 in your web browser should show you a short index and you can see test.php (use the lan address of the pc if your accessing from another pc on your lan). click on test.php and one of two things will happen either a pretty webpage gets loaded or your browser tries to download the file test.php.
if you get the webpage congratulations your past this hurdle. if not lets fix that.
first make sure you have this installed from synaptic libapache2-mod-php5
sudo synaptic
and look for libapache2-mod-php5 if its not installed then do so now
sudo /etc/init.d/apache2 restart
chances are test.php still will not work.
Debian, Ubuntu (Apache 2): file locations
ServerRoot :: /etc/apache2 DocumentRoot :: /var/www Apache Config Files :: /etc/apache2/apache2.conf :: /etc/apache2/ports.conf Default VHost Config :: /etc/apache2/sites-available/default, /etc/apache2/sites-enabled/000-default Module Locations :: /etc/apache2/mods-available, /etc/apache2/mods-enabled ErrorLog :: /var/log/apache2/error.log AccessLog :: /var/log/apache2/access.log cgi-bin :: /usr/lib/cgi-bin binaries (apachectl) :: /usr/sbin start/stop :: /etc/init.d/apache2 (start|stop|restart|reload|force-reload|start-htcacheclean|stop-htcacheclean)
This list is shamelessly lifted from http://wiki.apache.org/httpd/DistrosDefaultLayout
Take a look at the above list, its different on different distro's which is one of the reasons I am creating this page.
Module Locations :: /etc/apache2/mods-available, /etc/apache2/mods-enabled
Now this is where we must look for php. Debian has these two directories hopefully in /etc/apache2/mods-available you will see php5.load
easiest way to do this is with nautilus, type sudo nautilus in to a terminal and browse to mods-available can you see php5.load?
if so right click on it and select create shortcut, now click on that shortcut and select cut, move up to apache2 and select the directory mods-enabled, open that and select paste, you now have created a link to the php5.load file. rename the shortcut to php5.load and then exit nautilus
now
sudo /etc/init.d/apache2 restart
and go find test.php with your web-browser. clicking on it now should bring up a webpage congratulations you just enabled php in your apache webserver.
brief discussion
Debian decided this was an easy way to configure apache, in principle all modules exist within mods-available and all enabled mods will have a link in mods-enabled that points to the corresponding module in mods-available
so if there are other modules you need it seems in principle you need to install with synaptic and then once the module is in mods-available create a link to it in mods-enabled.
Theres two very similar folders sites-available and sites-enabled. I would hope that you can guess that this is pretty similar to the mods-available/ enabled folders. We may use this knowledge later...