update
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
{{ minecraft_server_dir }}/logs/*.log {
|
||||
daily
|
||||
missingok
|
||||
rotate 52
|
||||
compress
|
||||
delaycompress
|
||||
notifempty
|
||||
create 644 {{ minecraft_user }} {{ minecraft_group }}
|
||||
postrotate
|
||||
systemctl reload minecraft
|
||||
endscript
|
||||
}
|
@@ -0,0 +1,17 @@
|
||||
[Unit]
|
||||
Description=Minecraft Spigot Server
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=forking
|
||||
User={{ minecraft_user }}
|
||||
Group={{ minecraft_group }}
|
||||
WorkingDirectory={{ minecraft_server_dir }}
|
||||
ExecStart=/usr/bin/java -Xms{{ minecraft_memory_min }} -Xmx{{ minecraft_memory_max }} -jar {{ minecraft_server_dir }}/spigot.jar nogui
|
||||
ExecStop={{ minecraft_tools_dir }}/mcrcon -H 127.0.0.1 -P {{ minecraft_rcon_port }} -p {{ minecraft_rcon_password }} stop
|
||||
RemainAfterExit=yes
|
||||
RestartSec=15
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
10
roles/03-installation-minecraft/templates/ops.json.j2
Normal file
10
roles/03-installation-minecraft/templates/ops.json.j2
Normal file
@@ -0,0 +1,10 @@
|
||||
[
|
||||
{% for op in minecraft_ops | default([]) %}
|
||||
{
|
||||
"uuid": "{{ op.uuid }}",
|
||||
"name": "{{ op.name }}",
|
||||
"level": {{ op.level | default(4) }},
|
||||
"bypassesPlayerLimit": {{ op.bypass_limit | default(false) | lower }}
|
||||
}{% if not loop.last %},{% endif %}
|
||||
{% endfor %}
|
||||
]
|
@@ -0,0 +1,24 @@
|
||||
#Minecraft server properties
|
||||
server-name=Spigot Server
|
||||
server-port={{ minecraft_port }}
|
||||
max-players=20
|
||||
gamemode=survival
|
||||
difficulty=normal
|
||||
hardcore=false
|
||||
white-list=false
|
||||
enforce-whitelist=false
|
||||
pvp=true
|
||||
spawn-protection=16
|
||||
op-permission-level=4
|
||||
allow-flight=false
|
||||
enable-rcon=true
|
||||
rcon.port={{ minecraft_rcon_port }}
|
||||
rcon.password={{ minecraft_rcon_password }}
|
||||
motd=Minecraft Spigot Server managed by Ansible
|
||||
online-mode=true
|
||||
spawn-monsters=true
|
||||
generate-structures=true
|
||||
view-distance=10
|
||||
level-seed=
|
||||
level-name=world
|
||||
level-type=default
|
Reference in New Issue
Block a user