aboutsummaryrefslogtreecommitdiffstats
path: root/tasks/install_license.yml
diff options
context:
space:
mode:
authorStefan Joosten <stefan@sjoosten.nl>2016-08-25 16:21:09 +0200
committerStefan Joosten <stefan@sjoosten.nl>2016-08-25 16:21:09 +0200
commitb331fee529dc21d54b3a495d6fa68029a3920648 (patch)
tree1711f4d4f76f4b47b618cfa613d0ec7cad3b1941 /tasks/install_license.yml
parent819bb41873e49c520fc4506dfc00d46b6e849f44 (diff)
downloadansible-teamspeak-b331fee529dc21d54b3a495d6fa68029a3920648.tar.gz
ansible-teamspeak-b331fee529dc21d54b3a495d6fa68029a3920648.tar.xz
ansible-teamspeak-b331fee529dc21d54b3a495d6fa68029a3920648.zip
Add logic to install a TeamSpeak 3 Server License file to the target host. Fixes issue #3.
Diffstat (limited to 'tasks/install_license.yml')
-rw-r--r--tasks/install_license.yml18
1 files changed, 18 insertions, 0 deletions
diff --git a/tasks/install_license.yml b/tasks/install_license.yml
new file mode 100644
index 0000000..b54b551
--- /dev/null
+++ b/tasks/install_license.yml
@@ -0,0 +1,18 @@
+---
+# License install tasks for role teamspeak
+
+- name: "License : Create directory for license"
+ file:
+ path: "{{ teamspeak_licensepath }}"
+ state: directory
+ when: teamspeak_licensepath is not none
+
+- name: "License : Copy the license file"
+ copy:
+ src: licensekey.dat
+ dest: "{{ teamspeak_licensepath if teamspeak_licensepath is not none else ts3server_dir }}/licensekey.dat"
+ owner: "{{ teamspeak.user }}"
+ group: "{{ teamspeak.user }}"
+ mode: 0400
+ notify:
+ - Restart TeamSpeak 3 Server