summaryrefslogtreecommitdiff
path: root/dan/sk-tomnext.yml
blob: 4294880d5e9c7ddeafb27b7e08e3b0b87e944b2c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
---
- name: Basic Setup
  hosts: sk-tomnext
  roles:
  - role: base
  - role: sshd
  - role: zsh
  - role: admin-user
  - role: apt-repo/base
  - role: cryptdisk
  - role: zfs/base
  - role: apt-repo/spreadspace
  - role: zfs/sanoid
  - role: vm/host
  - 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  cryptdisk_volumes.items() %}
        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
        systemctl restart libvirtd.service