summaryrefslogtreecommitdiff
path: root/inventory/host_vars
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2020-05-23 05:40:09 +0200
committerChristian Pointner <equinox@spreadspace.org>2020-05-25 00:04:27 +0200
commit7783703ff07eb90fea5a1251032dc2901602219d (patch)
treeb92e4a7cf4cde4f3e773fd2e1dd41ebd4d968ac8 /inventory/host_vars
parentadd role zfs sanoid (diff)
major revamp for zfs based vm images
Diffstat (limited to 'inventory/host_vars')
-rw-r--r--inventory/host_vars/sk-tomnext-nc.yml36
-rw-r--r--inventory/host_vars/sk-tomnext.yml43
2 files changed, 60 insertions, 19 deletions
diff --git a/inventory/host_vars/sk-tomnext-nc.yml b/inventory/host_vars/sk-tomnext-nc.yml
new file mode 100644
index 00000000..a302a298
--- /dev/null
+++ b/inventory/host_vars/sk-tomnext-nc.yml
@@ -0,0 +1,36 @@
+---
+vm_host: sk-tomnext
+
+install:
+ host: "{{ vm_host }}"
+ mem: 16384
+ numcpu: 8
+ disks:
+ primary: /dev/sda
+ scsi:
+ sda:
+ type: zfs
+ name: root
+ size: 50g
+ sdb:
+ type: zfs
+ name: data
+ size: 20g
+ interfaces:
+ - bridge: br-public
+ name: primary0
+ autostart: False
+
+network:
+ nameservers: "{{ hostvars[vm_host].vm_host.network.dns }}"
+ domain: "{{ host_domain }}"
+ systemd_link:
+ interfaces: "{{ install.interfaces }}"
+ primary:
+ interface: primary0
+ ip: "{{ hostvars[vm_host].vm_host.network.bridges.public.prefix | ipaddr(hostvars[vm_host].vm_host.network.bridges.public.offsets[inventory_hostname]) | ipaddr('address') }}"
+ mask: "{{ hostvars[vm_host].vm_host.network.bridges.public.prefix | ipaddr('netmask') }}"
+ gateway: "{{ hostvars[vm_host].vm_host.network.bridges.public.prefix | ipaddr('address') }}"
+ overlay: "{{ (hostvars[vm_host].vm_host.network.bridges.public.overlay.prefix | ipaddr(hostvars[vm_host].vm_host.network.bridges.public.overlay.offsets[inventory_hostname])).split('/')[0] }}"
+
+external_ip: "{{ network.primary.overlay }}"
diff --git a/inventory/host_vars/sk-tomnext.yml b/inventory/host_vars/sk-tomnext.yml
index d570f1b2..57f3dcf1 100644
--- a/inventory/host_vars/sk-tomnext.yml
+++ b/inventory/host_vars/sk-tomnext.yml
@@ -11,25 +11,6 @@ network: {}
base_intel_nic_stability_fix: true
-vm_host:
- network:
- dns:
- - 213.133.100.100
- - 213.133.98.98
- - 213.133.99.99
- bridges:
- public:
- prefix: 192.168.250.254/24
- offsets:
- sk-tomnext-nc: 103
- sk-tomnext-hp: 104
- nat: yes
- overlay:
- prefix: 94.130.206.64/26
- offsets:
- sk-tomnext-nc: 39
- sk-tomnext-hp: 40
-
ssh_keys_root: "{{ ssh_keys.equinox[env_group] + ssh_keys.dan }}"
apt_repo_components:
@@ -65,3 +46,27 @@ zfs_sanoid_modules:
use_template: production
recursive: yes
process_children_only: yes
+
+
+vm_host:
+ network:
+ dns:
+ - 213.133.100.100
+ - 213.133.98.98
+ - 213.133.99.99
+ bridges:
+ public:
+ prefix: 192.168.250.254/24
+ offsets:
+ sk-tomnext-nc: 103
+ sk-tomnext-hp: 104
+ nat: yes
+ overlay:
+ prefix: 94.130.206.64/26
+ offsets:
+ sk-tomnext-nc: 39
+ sk-tomnext-hp: 40
+ zfs:
+ default:
+ pool: storage
+ name: vm