Skip to content

Instantly share code, notes, and snippets.

@massahud
Last active September 22, 2020 21:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save massahud/d4100c493e205e76837fde04a949c058 to your computer and use it in GitHub Desktop.
Save massahud/d4100c493e205e76837fde04a949c058 to your computer and use it in GitHub Desktop.
Minecraft bedrock server on aws lightsail
  1. create an lightsail OS Only Ubuntu instance
  2. turn on port forwarding of UDP
  3. set static ip
  4. ssh into the instance
  5. create and cd to /minecraft directory
  6. wget and unzip the latest bedrock server for ubuntu (https://www.minecraft.net/en-us/download/server/bedrock)
  7. create a run.sh (chmod 755) script with the following code:
#!/bin/bash
LD_LIBRARY_PATH=. ./bedrock_server
  1. edit server.settings and permissions.settings
  2. copy the following script into /etc/systemd/system/minecraft.server
[Unit]
Description=Minecraft Server
After=network.target

[Service]
User=ubuntu
Nice=1
KillMode=none
SuccessExitStatus=0 1
ProtectHome=true
ProtectSystem=full
PrivateDevices=true
NoNewPrivileges=true
WorkingDirectory=/minecraft
ExecStart=/minecraft/run.sh
ExecStop=killall bedrock_server

[Install]
WantedBy=multi-user.target
  1. Run the following commands
sudo systemctl daemon-reload
sudo systemctl start minecraft
sudo systemctl enable minecraft
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment