summaryrefslogtreecommitdiff
path: root/skillz/sk-tomnext.yml
diff options
context:
space:
mode:
Diffstat (limited to 'skillz/sk-tomnext.yml')
-rw-r--r--skillz/sk-tomnext.yml39
1 files changed, 39 insertions, 0 deletions
diff --git a/skillz/sk-tomnext.yml b/skillz/sk-tomnext.yml
new file mode 100644
index 00000000..8ad69918
--- /dev/null
+++ b/skillz/sk-tomnext.yml
@@ -0,0 +1,39 @@
+---
+- name: Basic Setup
+ hosts: sk-tomnext
+ roles:
+ - role: apt-repo/base
+ - role: core/base
+ - role: core/sshd/base
+ - role: core/zsh
+ - role: core/cpu-microcode
+ - role: core/users
+ - role: storage/luks/base
+ - role: storage/zfs/base
+ - role: storage/zfs/sanoid
+ - role: vm/host/base
+ - role: vm/host/network
+ - role: installer/debian/base
+ tasks:
+ - name: install post-boot script
+ copy:
+ dest: /usr/local/bin/post-boot
+ mode: 0755
+ content: |
+ #!/bin/bash
+ set -e
+
+ {% for name, volume in luks_devices.items() %}
+ echo -e "opening crypto volume: \033[1;37m{{ name }}\033[0m"
+ cryptsetup luksOpen '{{ volume.device }}' '{{ name }}'
+ {% endfor %}
+
+ systemctl restart zfs-import-cache.service
+ systemctl restart zfs-mount.service
+ systemctl restart zfs-share.service
+ systemctl restart zfs-zed.service
+ mount -a
+
+ sleep 2
+ rm -f /run/libvirt/qemu/autostarted
+ systemctl restart libvirtd.service