summaryrefslogtreecommitdiff
path: root/roles/apps/etherpad-lite
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2020-06-14 21:33:41 +0200
committerChristian Pointner <equinox@spreadspace.org>2020-06-14 21:33:41 +0200
commit3e462c69e5cc515e519dc2622ef151bb8d1ad386 (patch)
tree0aa926fdf24f2b783d2ae311bfbed6b465cf9277 /roles/apps/etherpad-lite
parentdocker/containerd/kubelet: more flexible handling of zfs properties (diff)
nextcloud/etherpad-lite imrpoved zfs property handling
Diffstat (limited to 'roles/apps/etherpad-lite')
-rw-r--r--roles/apps/etherpad-lite/defaults/main.yml6
-rw-r--r--roles/apps/etherpad-lite/tasks/main.yml8
2 files changed, 7 insertions, 7 deletions
diff --git a/roles/apps/etherpad-lite/defaults/main.yml b/roles/apps/etherpad-lite/defaults/main.yml
index 5281c739..0fa2df2d 100644
--- a/roles/apps/etherpad-lite/defaults/main.yml
+++ b/roles/apps/etherpad-lite/defaults/main.yml
@@ -10,7 +10,8 @@ etherpad_lite_db_gid: "941"
# etherpad_lite_zfs:
# pool: storage
# name: etherpad_lite
-# size: 20G
+# properties:
+# compression: lz4
# etherpad_lite_instances:
# example:
@@ -18,7 +19,8 @@ etherpad_lite_db_gid: "941"
# port: 8300
# hostnames:
# - pad.example.com
-# quota: 40G
+# zfs_properties:
+# quota: 5G
# settings:
# ....
# credentials:
diff --git a/roles/apps/etherpad-lite/tasks/main.yml b/roles/apps/etherpad-lite/tasks/main.yml
index 6d4551db..0beeb1e1 100644
--- a/roles/apps/etherpad-lite/tasks/main.yml
+++ b/roles/apps/etherpad-lite/tasks/main.yml
@@ -6,18 +6,16 @@
zfs:
name: "{{ etherpad_lite_zfs.pool }}/{{ etherpad_lite_zfs.name }}"
state: present
- extra_zfs_properties:
- quota: "{{ etherpad_lite_zfs.size }}"
+ extra_zfs_properties: "{{ etherpad_lite_zfs.properties | default(omit) }}"
- name: create zfs volumes for instances
loop: "{{ etherpad_lite_instances | dict2items }}"
loop_control:
- label: "{{ item.key }} ({{ item.value.quota }})"
+ label: "{{ item.key }} ({{ (item.value.zfs_properties | default({})).items() | map('join', '=') | join(', ') }})"
zfs:
name: "{{ etherpad_lite_zfs.pool }}/{{ etherpad_lite_zfs.name }}/{{ item.key }}"
state: present
- extra_zfs_properties:
- quota: "{{ item.value.quota }}"
+ extra_zfs_properties: "{{ item.value.zfs_properties | default(omit) }}"
- name: configure etherpad_lite base bath
set_fact: