summaryrefslogtreecommitdiff
path: root/spreadspace
diff options
context:
space:
mode:
Diffstat (limited to 'spreadspace')
-rw-r--r--spreadspace/glt-stream.yml55
1 files changed, 55 insertions, 0 deletions
diff --git a/spreadspace/glt-stream.yml b/spreadspace/glt-stream.yml
new file mode 100644
index 00000000..3a897377
--- /dev/null
+++ b/spreadspace/glt-stream.yml
@@ -0,0 +1,55 @@
+---
+- name: Basic Setup
+ hosts: glt-stream
+ roles:
+ - role: apt-repo/base
+ - role: core/base
+ - role: core/sshd
+ - role: core/zsh
+ - role: core/ntp
+ - role: apt-repo/spreadspace
+ - role: acmetool/base
+ - role: nginx/base
+ post_tasks:
+ - name: create logical volume
+ lvol:
+ vg: "{{ host_name }}"
+ lv: www
+ size: 10G
+
+ - name: create filesystem
+ filesystem:
+ fstype: ext4
+ dev: "/dev/mapper/{{ host_name | replace('-', '--') }}-www"
+
+ - name: mount filesytem
+ mount:
+ src: "/dev/mapper/{{ host_name | replace('-', '--') }}-www"
+ path: /srv/www
+ fstype: ext4
+ state: mounted
+
+ - name: create base directory for static www content
+ file:
+ path: /srv/www/stream
+ state: directory
+
+ - name: configure default vhost stream.linuxtage.at
+ vars:
+ nginx_vhost:
+ default: yes
+ name: stream
+ template: static-files-with-acme
+ acme: yes
+ hostnames:
+ - stream.linuxtage.at
+ root: /srv/www/stream
+ index: index.html
+ directives_extra:
+ server: |-
+ add_header Access-Control-Allow-Headers "origin,range,accept-encoding,referer";
+ add_header Access-Control-Allow-Methods "GET,HEAD,OPTIONS";
+ add_header Access-Control-Allow-Origin "*";
+ add_header Access-Control-Expose-Headers "Server,range,Content-Length,Content-Range,Date";
+ include_role:
+ name: nginx/vhost