I just finished building Ubuntu 10.4 and installed Zoneminder 1.24.2
In order to get to my ZM server, I have to go to:
http://myipaddress/zoneminder
I would like to have it so that all I had to do was go to:
http://myipaddress
and that would take me to the Zoneminder homepage. How do I set that?
Want Zoneminder to reside at root of IP address
As a quick hack you could do a PHP header(Location:) redirect in your index.php file in the root.
Alternately, the zoneminder.conf linked in your apache conf directory (eg: /etc/apache2/conf.d) contains an Alias for /zm (or /zoneminder in your case) pointing it to the ZM web-directory. You could remove this alias and set the 'DocumentRoot' parameter in your server apache configuration file to /usr/share/zoneminder (for example) instead, which will set that as the root.
Or take whatever directory serves as the root for your server right now, erase it and just symlink it to /usr/share/zoneminder... lots of ways around it
Alternately, the zoneminder.conf linked in your apache conf directory (eg: /etc/apache2/conf.d) contains an Alias for /zm (or /zoneminder in your case) pointing it to the ZM web-directory. You could remove this alias and set the 'DocumentRoot' parameter in your server apache configuration file to /usr/share/zoneminder (for example) instead, which will set that as the root.
Or take whatever directory serves as the root for your server right now, erase it and just symlink it to /usr/share/zoneminder... lots of ways around it

All those would work, plus:
Google for "htaccess redirect" to redirect anyone going to / to /zm instead
Create a /index.html that immediately redirects the user to /zm/ on load.
Possibly copying the contents of /zm into / might work, but backup first as I've not tried it. You might then need to link /zm to / for anything that expects it in the old location.
Google for "htaccess redirect" to redirect anyone going to / to /zm instead
Create a /index.html that immediately redirects the user to /zm/ on load.
Possibly copying the contents of /zm into / might work, but backup first as I've not tried it. You might then need to link /zm to / for anything that expects it in the old location.
-
- Posts: 36
- Joined: Wed Sep 09, 2009 4:47 pm
If you wish to do this with Red Hat / Fedora / CentOS, try this...
nano /etc/httpd/conf/httpd.conf
<VirtualHost>
ServerAdmin me@me.com
DocumentRoot /var/www/html/zm
ServerName yourservername
ErrorLog /var/log/httpd/VirtualHost-error_log
CustomLog /var/log/httpd/VirtualHost-Custom-error_log common
</VirtualHost>
nano /etc/httpd/conf/httpd.conf
<VirtualHost>
ServerAdmin me@me.com
DocumentRoot /var/www/html/zm
ServerName yourservername
ErrorLog /var/log/httpd/VirtualHost-error_log
CustomLog /var/log/httpd/VirtualHost-Custom-error_log common
</VirtualHost>