Actually set up the tes3mp server, tweak and configure it along with nightly backups
This commit is contained in:
parent
a5708348ca
commit
5e962f54c7
@ -2,13 +2,21 @@
|
||||
# vim:ft=ansible:
|
||||
# Game servers
|
||||
---
|
||||
- hosts: vm-test3mp-1.home.mgmt.desu.ltd
|
||||
- hosts: vm-tes3mp-1.home.mgmt.desu.ltd
|
||||
gather_facts: no
|
||||
roles:
|
||||
- role: docker-tes3mp
|
||||
vars:
|
||||
tes3mp_server_hostname: "The N'Wah Spitoon"
|
||||
tes3mp_server_port: "55455"
|
||||
tags: [ tes3mp ]
|
||||
- role: backup
|
||||
vars:
|
||||
backup_s3backup_list_extra:
|
||||
- /data
|
||||
backup_s3backup_exclude_list_extra:
|
||||
- /data/tes3mp/generic/backups
|
||||
tags: [ backup ]
|
||||
- hosts: vm-minecraft-2.home.mgmt.desu.ltd
|
||||
gather_facts: no
|
||||
roles:
|
||||
|
@ -14,6 +14,6 @@ tes3mp_external_port: 25565
|
||||
tes3mp_data_prefix: "/data/tes3mp/{{ tes3mp_name }}"
|
||||
|
||||
# TES3MP settings
|
||||
tes3mp_server_maximum_players: 8
|
||||
tes3mp_server_maximum_players: "8"
|
||||
tes3mp_server_hostname: "Some Ansible-deployed server"
|
||||
tes3mp_server_password: "dicks"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env ansible-playbook
|
||||
# vim:ft=ansible:
|
||||
- name: assure tes3mp {{ tes3mp_name }} directory structure
|
||||
file:
|
||||
ansible.builtin.file:
|
||||
state: directory
|
||||
owner: "{{ tes3mp_uid }}"
|
||||
group: "{{ tes3mp_gid }}"
|
||||
@ -10,7 +10,13 @@
|
||||
recurse: yes
|
||||
with_items:
|
||||
- "{{ tes3mp_data_prefix }}/data"
|
||||
- "{{ tes3mp_data_prefix }}/scripts"
|
||||
- "{{ tes3mp_data_prefix }}/backups"
|
||||
- name: assure tes3mp {{ tes3mp_name }} backup cronjob
|
||||
ansible.builtin.cron:
|
||||
user: root
|
||||
name: "tes3mp-{{ tes3mp_name }}"
|
||||
minute: "*/10"
|
||||
job: "tar czvf \"{{ tes3mp_data_prefix }}/backups/tes3mp-$(date +%Y-%M-%d-%H%M).tgz\" \"{{ tes3mp_data_prefix }}/data\""
|
||||
- name: assure tes3mp {{ tes3mp_name }} container
|
||||
docker_container:
|
||||
name: "tes3mp-{{ tes3mp_name }}"
|
||||
@ -28,4 +34,3 @@
|
||||
- "25565:25565/udp"
|
||||
volumes:
|
||||
- "{{ tes3mp_data_prefix }}/data:/server/data"
|
||||
- "{{ tes3mp_data_prefix }}/scripts:/server/scripts"
|
||||
|
Loading…
Reference in New Issue
Block a user