Setting up Dynamic Map with Apache2 under Debian - Neder/dynmap GitHub Wiki
This page assumes:
- You have apache2 installed.
- Your www-root directory to be:
/srv/http/. - You could access your Dynmap-map succesfully through http://localhost:8123/.
This example shows how to put dynmap on your apache2 webserver in http://mywebserver/dynmap/.
- To start, create the directory
/srv/http/dynmap/. - Copy the contents of the
webdirectory found in the zip to/srv/http/dynmap/.
First, we need to enable the modules we need. Type in bash:
sudo a2enmod rewrite proxy_httpNext, we must 'redirect' /dynmap/up/ and /dynmap/standalone/ to dynmap's internal webserver. To do this, make sure you have the following at the end of /etc/apache2/sites-available/default:
...
Alias /dynmap/tiles /opt/minecraft_server/plugins/dynmap/web/tiles/
RewriteEngine on
RewriteRule /dynmap/up/(.*) http://localhost:8123/up/$1 [P,L]
RewriteRule /dynmap/standalone/(.*) http://localhost:8123/standalone/$1 [P,L]
</VirtualHost>
<Directory /opt/minecraft_server/plugins/dynmap/web/tiles/>
Order allow,deny
Allow from all
</Directory>
<Proxy http://localhost:8123/*>
Order deny,allow
Allow from all
</Proxy>Restart apache2 (sudo /etc/init.d/apache2 restart).
It should now display online players on http://mywebserver/dynmap/, keeping them up-to-date.