Last active
August 29, 2015 14:12
-
-
Save aaronlerch/15369228265cda5bbd3d to your computer and use it in GitHub Desktop.
Example configuration and update script for running The Minecraft Overviewer and uploading it to S3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
worlds["myserver"] = "/opt/msm/servers/myserver/world" | |
def playerIcons(poi): | |
if poi['id'] == 'Player': | |
poi['icon'] = "http://overviewer.org/avatar/%s" % poi['EntityId'] | |
return "Last known location for %s" % poi['EntityId'] | |
def signFilter(poi): | |
if poi['id'] == 'Sign': | |
return "\n".join([poi['Text1'], poi['Text2'], poi['Text3'], poi['Text4']]) | |
renders["normalday"] = { | |
"world": "myserver", | |
"title": "Daytime", | |
"rendermode": smooth_lighting, | |
"dimension": "overworld", | |
"markers": [dict(name="All signs", filterFunction=signFilter), | |
dict(name="All players", filterFunction=playerIcons)], | |
} | |
renders["caves"] = { | |
"world": "myserver", | |
"title": "Caves", | |
"rendermode": cave, | |
"dimension": "overworld", | |
"markers": [dict(name="All players", filterFunction=playerIcons)], | |
} | |
# Uncomment the line below if you want to customize the default index.html | |
# customwebassets = "/opt/msm/.overviewer/customassets" | |
outputdir = "/usr/share/nginx/html/map" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -euo pipefail | |
IFS=$'\n\t' | |
# Generate the waypoints | |
overviewer.py --config=/opt/msm/.overviewer/overviewer.conf --genpoi | |
# Generate the map | |
overviewer.py --config=/opt/msm/.overviewer/overviewer.conf | |
# Upload the map to S3 | |
aws s3 sync /usr/share/nginx/html/map/ s3://insert-your-bucket-name-here/ --region=us-east-1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment