summaryrefslogtreecommitdiff
path: root/spreadspace
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2022-01-01 17:13:26 +0100
committerChristian Pointner <equinox@spreadspace.org>2022-01-02 23:26:17 +0100
commita9c5560dcca18a0df93341289087a9585fbca29c (patch)
treebe284c40faea1e61f8304e49dcc7a9d0788be193 /spreadspace
parentminor cleanup for grafana dashboards (diff)
add new openwrt-based testvm
add new vm-deploy playbook and script
Diffstat (limited to 'spreadspace')
-rw-r--r--spreadspace/image-generate.yml13
-rw-r--r--spreadspace/vm-deploy.yml18
2 files changed, 31 insertions, 0 deletions
diff --git a/spreadspace/image-generate.yml b/spreadspace/image-generate.yml
index a7d38149..4c2f5fb9 100644
--- a/spreadspace/image-generate.yml
+++ b/spreadspace/image-generate.yml
@@ -5,3 +5,16 @@
gather_facts: no
roles:
- role: "{{ install_distro }}/image"
+ post_tasks:
+ - pause:
+ seconds: 0
+ prompt: |
+ The resulting images can be found here:
+
+ {% for host in play_hosts %}
+ {{ host }}:
+ {% for image in hostvars[host].output_images %}
+ - {{ image }}
+ {% endfor %}
+
+ {% endfor %}
diff --git a/spreadspace/vm-deploy.yml b/spreadspace/vm-deploy.yml
new file mode 100644
index 00000000..33268b6d
--- /dev/null
+++ b/spreadspace/vm-deploy.yml
@@ -0,0 +1,18 @@
+---
+- name: generate os image
+ hosts: "{{ install_hostname }}"
+ connection: local
+ gather_facts: no
+ roles:
+ - role: "{{ install_distro }}/image"
+
+- name: cook variables for host
+ hosts: "{{ install_hostname }}"
+ gather_facts: no
+ tasks:
+ - set_fact:
+ install: "{{ install | default({}) }}"
+ network: "{{ network | default({}) }}"
+ vm_host: "{{ vm_host | default({}) }}"
+
+- import_playbook: ../common/vm-deploy.yml