Deleted vanilla minecraft in favor of papermc.
authorLuke Hoersten <luke@hoersten.org>
Sun, 07 Jun 2020 21:56:03 -0500
changeset 35 87e0c39ac37d
parent 34 ecbdaed7f151
child 36 a8627367c7be
Deleted vanilla minecraft in favor of papermc.
minecraft/defaults/main.yaml
minecraft/files/eula.txt
minecraft/files/ops.json
minecraft/handlers/main.yaml
minecraft/tasks/main.yaml
minecraft/templates/minecraft.service.j2
minecraft/templates/server.properties.j2
--- a/minecraft/defaults/main.yaml	Sun Jun 07 21:55:46 2020 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,6 +0,0 @@
----
-
-minecraft_user: "minecraft"
-minecraft_url: "https://launcher.mojang.com/v1/objects/bb2b6b1aefcd70dfd1892149ac3a215f6c636b07/server.jar"
-minecraft_dir: "/opt/minecraft"
-minecraft_motd: ""
--- a/minecraft/files/eula.txt	Sun Jun 07 21:55:46 2020 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-eula=true
--- a/minecraft/files/ops.json	Sun Jun 07 21:55:46 2020 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,8 +0,0 @@
-[
-  {
-    "uuid": "98827ef9-601c-49fd-b575-abc8de019854",
-    "name": "Lukemute",
-    "level": 4,
-    "bypassesPlayerLimit": true
-  }
-]
\ No newline at end of file
--- a/minecraft/handlers/main.yaml	Sun Jun 07 21:55:46 2020 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
----
-
-- name: restart minecraft
-  become: yes
-  systemd: name="minecraft.service" state="restarted" daemon_reload="yes"
--- a/minecraft/tasks/main.yaml	Sun Jun 07 21:55:46 2020 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
----
-
-- name: add minecract user
-  become: yes
-  user: name="{{minecraft_user}}" home="{{minecraft_dir}}"
-
-- name: install jre
-  become: yes
-  apt: name="default-jre-headless"
-
-- name: download minecraft
-  become: yes
-  get_url:
-    url: "{{minecraft_url}}"
-    dest: "{{minecraft_dir}}/server.jar"
-    mode: "0755"
-  notify: restart minecraft
-
-- name: configure eula and ops
-  become: yes
-  copy:
-    src: "{{item}}"
-    dest: "{{minecraft_dir}}/{{item}}"
-    owner: "{{minecraft_user}}"
-    group: "{{minecraft_user}}"
-  loop:
-    - "eula.txt"
-    - "ops.json"
-  notify: restart minecraft
-
-# minecraft server writes a timtestamp to the config every time it starts so this always generates a change.
-- name: configure minecraft
-  become: yes
-  template:
-    src: "server.properties.j2"
-    dest: "{{minecraft_dir}}/server.properties"
-    owner: "{{minecraft_user}}"
-    group: "{{minecraft_user}}"
-  changed_when: false
-
-- name: install systemd service
-  become: yes
-  template:
-    src: "minecraft.service.j2"
-    dest: "/lib/systemd/system/minecraft.service"
-  notify: restart minecraft
-
-- name: ensure service is started
-  become: yes
-  systemd: name="minecraft.service" enabled="yes" state="started"
--- a/minecraft/templates/minecraft.service.j2	Sun Jun 07 21:55:46 2020 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,22 +0,0 @@
-[Unit]
-Description=Minecraft Server
-Documentation=https://minecraft.gamepedia.com/Tutorials/Setting_up_a_server
-
-Wants=network.target
-After=network.target
-
-[Service]
-User={{minecraft_user}}
-Group={{minecraft_user}}
-WorkingDirectory={{minecraft_dir}}
-Restart=on-failure
-RestartSec=20 5
-ExecStart=/usr/bin/java -Xms1536M -Xmx1536M -jar server.jar nogui
-
-PrivateTmp=true
-ProtectSystem=full
-NoNewPrivileges=true
-PrivateDevices=true
-
-[Install]
-WantedBy=multi-user.target
--- a/minecraft/templates/server.properties.j2	Sun Jun 07 21:55:46 2020 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,44 +0,0 @@
-broadcast-rcon-to-ops=true
-view-distance=10
-max-build-height=256
-server-ip=
-level-seed=
-rcon.port=25575
-gamemode=survival
-server-port=25565
-allow-nether=true
-enable-command-block=false
-enable-rcon=false
-enable-query=false
-op-permission-level=4
-prevent-proxy-connections=false
-generator-settings=
-resource-pack=
-level-name=world
-rcon.password=
-player-idle-timeout=0
-motd={{minecraft_motd}}
-query.port=25565
-force-gamemode=false
-hardcore=false
-white-list=false
-broadcast-console-to-ops=true
-pvp=true
-spawn-npcs=true
-generate-structures=true
-spawn-animals=true
-snooper-enabled=true
-difficulty=easy
-function-permission-level=2
-network-compression-threshold=256
-level-type=default
-spawn-monsters=true
-max-tick-time=60000
-enforce-whitelist=false
-use-native-transport=true
-max-players=20
-resource-pack-sha1=
-spawn-protection=16
-online-mode=true
-allow-flight=false
-max-world-size=29999984
\ No newline at end of file