Updated Configuring Multiple Servers (markdown)
parent
04eada383e
commit
5269d271e3
@ -52,39 +52,43 @@ This subdirectory-based approach was chosen for its relative simplicity and beca
|
||||
|
||||
Multiple server support is configured in index.html. Look for the `<script>` containing the `window.liveAtlasConfig` object and edit the `servers` property to include the servers you want to be accessible within LiveAtlas. The key of each server object will be used in the URL to access it.
|
||||
|
||||
Each server object should contain a `dynmap`, `squaremap` or `pl3xmap` property which contains the URLs necessary for displaying the map. Dynmap maps require several URLs which can be found in the `standalone/config.js` file for the server. Squaremap and Pl3xmap maps require just the URL the map is currently viewable at. Making all URLs absolute is recommended to avoid ambiguity.
|
||||
Each server object should contain a `dynmap`, `squaremap`, `pl3xmap` or `overviewer` property which contains the URLs necessary for displaying the map. Dynmap maps require several URLs which can be found in the `standalone/config.js` file for the server. Squaremap, Pl3xmap and Overviewer maps require just the URL the map is currently viewable at. Making all URLs absolute is recommended to avoid ambiguity.
|
||||
|
||||
An example with 2 dynmap servers named `creative` and `survival` and a 3rd Pl3xmap server:
|
||||
An example with 2 dynmap servers named `creative` and `survival` and additional Pl3xmap and Overviewer servers:
|
||||
|
||||
window.liveAtlasConfig = {
|
||||
servers: {
|
||||
creative: {
|
||||
label: 'Creative',
|
||||
dynmap: {
|
||||
configuration: 'http://example.com/creative/standalone/MySQL_configuration.php',
|
||||
update: 'http://example.com/creative/standalone/MySQL_update.php?world={world}&ts={timestamp}',
|
||||
sendmessage: 'http://example.com/creative/standalone/MySQL_sendmessage.php',
|
||||
login: 'http://example.com/creative/standalone/MySQL_login.php',
|
||||
register: 'http://example.com/creative/standalone/MySQL_register.php',
|
||||
tiles: 'http://example.com/creative/standalone/MySQL_tiles.php?tile=',
|
||||
markers: 'http://example.com/creative/standalone/MySQL_markers.php?marker='
|
||||
configuration: 'https://example.com/backend/creative/standalone/MySQL_configuration.php',
|
||||
update: 'https://example.com/backend/creative/standalone/MySQL_update.php?world={world}&ts={timestamp}',
|
||||
sendmessage: 'https://example.com/backend/creative/standalone/MySQL_sendmessage.php',
|
||||
login: 'https://example.com/backend/creative/standalone/MySQL_login.php',
|
||||
register: 'https://example.com/backend/creative/standalone/MySQL_register.php',
|
||||
tiles: 'https://example.com/backend/creative/standalone/MySQL_tiles.php?tile=',
|
||||
markers: 'https://example.com/backend/creative/standalone/MySQL_markers.php?marker='
|
||||
}
|
||||
},
|
||||
survival: {
|
||||
label: 'Survival',
|
||||
dynmap: {
|
||||
configuration: 'http://example.com/survival/standalone/MySQL_configuration.php',
|
||||
update: 'http://example.com/survival/standalone/MySQL_update.php?world={world}&ts={timestamp}',
|
||||
sendmessage: 'http://example.com/survival/standalone/MySQL_sendmessage.php',
|
||||
login: 'http://example.com/survival/standalone/MySQL_login.php',
|
||||
register: 'http://example.com/survival/standalone/MySQL_register.php',
|
||||
tiles: 'http://example.com/survival/standalone/MySQL_tiles.php?tile=',
|
||||
markers: 'http://example.com/survival/standalone/MySQL_markers.php?marker='
|
||||
configuration: 'https://example.com/backend/survival/standalone/MySQL_configuration.php',
|
||||
update: 'https://example.com/backend/survival/standalone/MySQL_update.php?world={world}&ts={timestamp}',
|
||||
sendmessage: 'https://example.com/backend/survival/standalone/MySQL_sendmessage.php',
|
||||
login: 'https://example.com/backend/survival/standalone/MySQL_login.php',
|
||||
register: 'https://example.com/backend/survival/standalone/MySQL_register.php',
|
||||
tiles: 'https://example.com/backend/survival/standalone/MySQL_tiles.php?tile=',
|
||||
markers: 'https://example.com/backend/survival/standalone/MySQL_markers.php?marker='
|
||||
}
|
||||
},
|
||||
pl3xmap: {
|
||||
label: 'Pl3xmap',
|
||||
pl3xmap: 'http://example.com/pl3xmap/'
|
||||
pl3xmapexample: {
|
||||
label: 'Pl3xmap Example',
|
||||
pl3xmap: 'https://example.com/backend/pl3xmap/'
|
||||
},
|
||||
overviewerexample: {
|
||||
label: 'Overviewer Example',
|
||||
pl3xmap: 'https://example.com/backend/overviewer/'
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -95,6 +99,6 @@ This subdirectory-based approach was chosen for its relative simplicity and beca
|
||||
|
||||
4. Test
|
||||
|
||||
Visit the URL you are hosting LiveAtlas at (in our example `http://example.com/map/`) and check everything works correctly. Make sure to test the individual server URLs (`http://example.com/map/survival`, `http://example.com/map/creative` and `http://example.com/map/pl3xmap` in this case) as well.
|
||||
Visit the URL you are hosting LiveAtlas at (in our example `http://example.com/map/`) and check everything works correctly. Make sure to test the individual server URLs (`http://example.com/map/survival`, `http://example.com/map/creative`, `http://example.com/map/pl3xmapexample` and `http://example.com/map/overviewerexample` in this case) as well.
|
||||
|
||||
If a server isn't configured correctly, LiveAtlas will display an error on the splash screen informing you of the problem. If the configuration is valid, try switching to all the configured servers and check they load correctly. If a server doesn't load correctly, check the browser console for more details on why and reconfigure as required.
|
Loading…
Reference in New Issue
Block a user