summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2020-01-30 12:57:27 +0100
committerChristian Pointner <equinox@spreadspace.org>2020-01-30 12:57:27 +0100
commit255baed9440e5656abc225461788a1b265c1e814 (patch)
tree5bacd5bacab53a8a8f3484671de1e18109a71935
parentadded ele-ups router (diff)
minor cleanups and whitespace fixes
-rw-r--r--chaos-at-home/ch-ap.yml6
-rw-r--r--chaos-at-home/ch-router.yml6
-rw-r--r--chaos-at-home/ch-sw0.yml6
-rw-r--r--chaos-at-home/ch-sw1.yml6
-rw-r--r--chaos-at-home/mz-ap.yml6
-rw-r--r--chaos-at-home/mz-router.yml16
-rw-r--r--chaos-at-home/r3-cccamp19-gw.yml2
-rw-r--r--chaos-at-home/r3-cccamp19-sw0.yml6
-rw-r--r--chaos-at-home/r3-vex2.yml6
-rw-r--r--common/usb-install.yml132
-rw-r--r--dan/ele-ap.yml24
-rw-r--r--dan/ele-dolmetsch-ctl.yml6
-rw-r--r--dan/ele-dolmetsch-raspi.yml13
-rw-r--r--dan/ele-router.yml6
-rw-r--r--dan/ele-ups.yml23
-rw-r--r--dan/info-beamer.yml10
16 files changed, 138 insertions, 136 deletions
diff --git a/chaos-at-home/ch-ap.yml b/chaos-at-home/ch-ap.yml
index 085b40c3..1d3c8903 100644
--- a/chaos-at-home/ch-ap.yml
+++ b/chaos-at-home/ch-ap.yml
@@ -1,6 +1,6 @@
---
-- hosts: chaos-at-home-ap
+- name: Basic Setup
+ hosts: chaos-at-home-ap
connection: local
roles:
- - role: openwrt/image
- delegate_to: localhost
+ - role: openwrt/image
diff --git a/chaos-at-home/ch-router.yml b/chaos-at-home/ch-router.yml
index 5fa1ca5f..f61feb15 100644
--- a/chaos-at-home/ch-router.yml
+++ b/chaos-at-home/ch-router.yml
@@ -1,6 +1,6 @@
---
-- hosts: ch-router
+- name: Basic Setup
+ hosts: ch-router
connection: local
roles:
- - role: openwrt/image
- delegate_to: localhost
+ - role: openwrt/image
diff --git a/chaos-at-home/ch-sw0.yml b/chaos-at-home/ch-sw0.yml
index fd0dedd0..c3d02802 100644
--- a/chaos-at-home/ch-sw0.yml
+++ b/chaos-at-home/ch-sw0.yml
@@ -3,6 +3,6 @@
hosts: ch-sw0
gather_facts: no
roles:
- - dellos6/bootstrap
- - dellos6/base
- - dellos6/layer2
+ - role: dellos6/bootstrap
+ - role: dellos6/base
+ - role: dellos6/layer2
diff --git a/chaos-at-home/ch-sw1.yml b/chaos-at-home/ch-sw1.yml
index 0d86fa48..ed7b0be5 100644
--- a/chaos-at-home/ch-sw1.yml
+++ b/chaos-at-home/ch-sw1.yml
@@ -3,6 +3,6 @@
hosts: ch-sw1
gather_facts: no
roles:
- - dellos6/bootstrap
- - dellos6/base
- - dellos6/layer2
+ - role: dellos6/bootstrap
+ - role: dellos6/base
+ - role: dellos6/layer2
diff --git a/chaos-at-home/mz-ap.yml b/chaos-at-home/mz-ap.yml
index e4e3a1fe..ccae1763 100644
--- a/chaos-at-home/mz-ap.yml
+++ b/chaos-at-home/mz-ap.yml
@@ -1,6 +1,6 @@
---
-- hosts: mz-ap
+- name: Basic Setup
+ hosts: mz-ap
connection: local
roles:
- - role: openwrt/image
- delegate_to: localhost
+ - role: openwrt/image
diff --git a/chaos-at-home/mz-router.yml b/chaos-at-home/mz-router.yml
index 2095632e..301da764 100644
--- a/chaos-at-home/mz-router.yml
+++ b/chaos-at-home/mz-router.yml
@@ -1,14 +1,14 @@
---
-- hosts: mz-router
+- name: Basic Setup
+ hosts: mz-router
connection: local
roles:
- - role: openwrt/image
- delegate_to: localhost
+ - role: openwrt/image
post_tasks:
- - pause:
- prompt: "\n****** copy and install image onto router and wait for it to come back ******\n"
+ - pause:
+ prompt: "\n****** copy and install image onto router and wait for it to come back ******\n"
- - shell: "base64 -d | ssh chmz-router \"/bin/sh -c 'umask 077; cat > /etc/dyndns/id_rsa'\""
- args:
- stdin: "{{ vault_dyndns_ssh_key_b64 }}"
+ - shell: "base64 -d | ssh chmz-router \"/bin/sh -c 'umask 077; cat > /etc/dyndns/id_rsa'\""
+ args:
+ stdin: "{{ vault_dyndns_ssh_key_b64 }}"
diff --git a/chaos-at-home/r3-cccamp19-gw.yml b/chaos-at-home/r3-cccamp19-gw.yml
index d729471a..e92370ac 100644
--- a/chaos-at-home/r3-cccamp19-gw.yml
+++ b/chaos-at-home/r3-cccamp19-gw.yml
@@ -2,4 +2,4 @@
- name: configure dyndns
hosts: r3-cccamp19-gw
roles:
- - dyndns/client
+ - role: dyndns/client
diff --git a/chaos-at-home/r3-cccamp19-sw0.yml b/chaos-at-home/r3-cccamp19-sw0.yml
index 1fbeb452..36ee99f5 100644
--- a/chaos-at-home/r3-cccamp19-sw0.yml
+++ b/chaos-at-home/r3-cccamp19-sw0.yml
@@ -3,6 +3,6 @@
hosts: r3-cccamp19-sw0
gather_facts: no
roles:
- - dellos6/bootstrap
- - dellos6/base
- - dellos6/layer2
+ - role: dellos6/bootstrap
+ - role: dellos6/base
+ - role: dellos6/layer2
diff --git a/chaos-at-home/r3-vex2.yml b/chaos-at-home/r3-vex2.yml
index 0369175b..4efac0a8 100644
--- a/chaos-at-home/r3-vex2.yml
+++ b/chaos-at-home/r3-vex2.yml
@@ -2,6 +2,6 @@
- name: nothing to see here
hosts: r3-vex2
tasks:
- - name: do nothing
- debug:
- msg: "all the rest is done using the realraum ansible repo"
+ - name: do nothing
+ debug:
+ msg: "all the rest is done using the realraum ansible repo"
diff --git a/common/usb-install.yml b/common/usb-install.yml
index b505ab01..db9faf7e 100644
--- a/common/usb-install.yml
+++ b/common/usb-install.yml
@@ -5,84 +5,84 @@
gather_facts: no
vars_prompt:
- - name: usbdrive_path
- prompt: Where is the USB installation medium mounted to?
- default: ""
- private: no
+ - name: usbdrive_path
+ prompt: Where is the USB installation medium mounted to?
+ default: ""
+ private: no
pre_tasks:
- - set_fact:
- artifacts_dir: "{{ global_artifacts_dir }}/{{ hostname }}"
- installer_path: "{{ global_cache_dir }}/debian-installer"
+ - set_fact:
+ artifacts_dir: "{{ global_artifacts_dir }}/{{ hostname }}"
+ installer_path: "{{ global_cache_dir }}/debian-installer"
- - file:
- state: directory
- name: "{{ artifacts_dir }}"
+ - file:
+ state: directory
+ name: "{{ artifacts_dir }}"
roles:
- - usb-install
+ - role: usb-install
- tasks:
- - stat:
- path: "{{ usbdrive_path }}"
- register: pathcheck
+ post_tasks:
+ - stat:
+ path: "{{ usbdrive_path }}"
+ register: pathcheck
- - when: pathcheck.stat.exists
- block:
- - name: Copy generated files to the USB drive
- loop:
- - "{{ artifacts_dir }}/initrd.preseed.gz"
- - "{{ global_cache_dir }}/debian-installer/{{ install_distro }}-{{ install_codename }}/{{ install.arch | default('amd64') }}/linux"
- loop_control:
- label: "{{ item | basename }}"
- copy:
- src: "{{ item }}"
- dest: "{{ usbdrive_path }}/"
+ - when: pathcheck.stat.exists
+ block:
+ - name: Copy generated files to the USB drive
+ loop:
+ - "{{ artifacts_dir }}/initrd.preseed.gz"
+ - "{{ global_cache_dir }}/debian-installer/{{ install_distro }}-{{ install_codename }}/{{ install.arch | default('amd64') }}/linux"
+ loop_control:
+ label: "{{ item | basename }}"
+ copy:
+ src: "{{ item }}"
+ dest: "{{ usbdrive_path }}/"
- - name: Generate syslinux configuration for BIOS boot
- copy:
- dest: "{{ usbdrive_path }}/syslinux.cfg"
- content: |
- DEFAULT linux
- SAY SYSLINUX booting an automated installer for {{ hostname }}...
- LABEL linux
- KERNEL linux
- INITRD initrd.preseed.gz
- APPEND install {{ (install.kernel_cmdline | default([])) | join(' ') }}
+ - name: Generate syslinux configuration for BIOS boot
+ copy:
+ dest: "{{ usbdrive_path }}/syslinux.cfg"
+ content: |
+ DEFAULT linux
+ SAY SYSLINUX booting an automated installer for {{ hostname }}...
+ LABEL linux
+ KERNEL linux
+ INITRD initrd.preseed.gz
+ APPEND install {{ (install.kernel_cmdline | default([])) | join(' ') }}
- - name: create EFI boot directory
- file:
- path: "{{ usbdrive_path }}/EFI/boot"
- state: directory
+ - name: create EFI boot directory
+ file:
+ path: "{{ usbdrive_path }}/EFI/boot"
+ state: directory
- - name: Generate syslinux configuration for UEFI boot
- copy:
- dest: "{{ usbdrive_path }}/EFI/boot/syslinux.cfg"
- content: |
- DEFAULT linux
- SAY SYSLINUX booting an automated installer for {{ hostname }}...
- LABEL linux
- KERNEL ../../linux
- INITRD ../../initrd.preseed.gz
- APPEND install {{ (install.kernel_cmdline | default([])) | join(' ') }}
+ - name: Generate syslinux configuration for UEFI boot
+ copy:
+ dest: "{{ usbdrive_path }}/EFI/boot/syslinux.cfg"
+ content: |
+ DEFAULT linux
+ SAY SYSLINUX booting an automated installer for {{ hostname }}...
+ LABEL linux
+ KERNEL ../../linux
+ INITRD ../../initrd.preseed.gz
+ APPEND install {{ (install.kernel_cmdline | default([])) | join(' ') }}
- - name: Make the USB disk bootable
- pause:
- seconds: 0
- prompt: |
- You should make sure the USB disk is bootable and
- has syslinux installed.
+ - name: Make the USB disk bootable
+ pause:
+ seconds: 0
+ prompt: |
+ You should make sure the USB disk is bootable and
+ has syslinux installed.
- $ sudo apt install mbr syslinux
- $ sudo install-mbr /dev/CHANGEME
- $ sudo syslinux -i /dev/CHANGEME1
- $ sudo fdisk /dev/CHANGEME
- [Here, make sure partition 1 is marked bootable.]
+ $ sudo apt install mbr syslinux
+ $ sudo install-mbr /dev/CHANGEME
+ $ sudo syslinux -i /dev/CHANGEME1
+ $ sudo fdisk /dev/CHANGEME
+ [Here, make sure partition 1 is marked bootable.]
- for UEFI these steps need to be done
+ for UEFI these steps need to be done
- $ sudo apt install syslinux-efi
- $ cp /usr/lib/syslinux/modules/efi64/* {{ usbdrive_path }}/EFI/boot/
- $ cp /usr/lib/SYSLINUX.EFI/efi64/syslinux.efi {{ usbdrive_path }}/EFI/boot/bootx64.efi
+ $ sudo apt install syslinux-efi
+ $ cp /usr/lib/syslinux/modules/efi64/* {{ usbdrive_path }}/EFI/boot/
+ $ cp /usr/lib/SYSLINUX.EFI/efi64/syslinux.efi {{ usbdrive_path }}/EFI/boot/bootx64.efi
- This will NOT be done automatically.
+ This will NOT be done automatically.
diff --git a/dan/ele-ap.yml b/dan/ele-ap.yml
index a64ed8a4..7230dea6 100644
--- a/dan/ele-ap.yml
+++ b/dan/ele-ap.yml
@@ -1,18 +1,18 @@
---
-- hosts: ele-ap
+- name: Basic Setup
+ hosts: ele-ap
connection: local
roles:
- - role: openwrt/image
- delegate_to: localhost
+ - role: openwrt/image
post_tasks:
- - name: copy image to target
- command: "scp '{{ openwrt_output_images[0] }}' '{{ inventory_hostname }}:/tmp/ansible-upgrade.img'"
+ - name: copy image to target
+ command: "scp '{{ openwrt_output_images[0] }}' '{{ inventory_hostname }}:/tmp/ansible-upgrade.img'"
- - name: run sysupgrade
- command: "ssh '{{ inventory_hostname }}' sysupgrade -n '/tmp/ansible-upgrade.img'"
- ignore_errors: true
- failed_when: false
- register: sysupgrade_result
+ - name: run sysupgrade
+ command: "ssh '{{ inventory_hostname }}' sysupgrade -n '/tmp/ansible-upgrade.img'"
+ ignore_errors: true
+ failed_when: false
+ register: sysupgrade_result
- - debug:
- var: sysupgrade_result.stdout
+ - debug:
+ var: sysupgrade_result.stdout
diff --git a/dan/ele-dolmetsch-ctl.yml b/dan/ele-dolmetsch-ctl.yml
index d16cfbdb..717def3f 100644
--- a/dan/ele-dolmetsch-ctl.yml
+++ b/dan/ele-dolmetsch-ctl.yml
@@ -1,6 +1,6 @@
---
-- hosts: ele-dolmetsch-ctl
+- name: Basic Setup
+ hosts: ele-dolmetsch-ctl
connection: local
roles:
- - role: openwrt/image
- delegate_to: localhost
+ - role: openwrt/image
diff --git a/dan/ele-dolmetsch-raspi.yml b/dan/ele-dolmetsch-raspi.yml
index 5b1068e0..daf4e3b4 100644
--- a/dan/ele-dolmetsch-raspi.yml
+++ b/dan/ele-dolmetsch-raspi.yml
@@ -1,8 +1,9 @@
---
-- hosts: ele-dolmetsch-raspi
+- name: Basic Setup
+ hosts: ele-dolmetsch-raspi
roles:
- - role: slim/raspbian
- - role: base
- - role: sshd
- - role: zsh
- - role: elevate/dolmetsch-raspi
+ - role: slim/raspbian
+ - role: base
+ - role: sshd
+ - role: zsh
+ - role: elevate/dolmetsch-raspi
diff --git a/dan/ele-router.yml b/dan/ele-router.yml
index 4f3d1ceb..098b82b3 100644
--- a/dan/ele-router.yml
+++ b/dan/ele-router.yml
@@ -1,6 +1,6 @@
---
-- hosts: ele-router
+- name: Basic Setup
+ hosts: ele-router
connection: local
roles:
- - role: openwrt/image
- delegate_to: localhost
+ - role: openwrt/image
diff --git a/dan/ele-ups.yml b/dan/ele-ups.yml
index 7843c1ff..fa780eaf 100644
--- a/dan/ele-ups.yml
+++ b/dan/ele-ups.yml
@@ -1,17 +1,18 @@
---
-- hosts: ele-ups
+- name: Basic Setup
+ hosts: ele-ups
connection: local
roles:
- - role: openwrt/image
+ - role: openwrt/image
# post_tasks:
- # - name: copy image to target
- # command: "scp '{{ openwrt_output_images[0] }}' '{{ inventory_hostname }}:/tmp/ansible-upgrade.img'"
+ # - name: copy image to target
+ # command: "scp '{{ openwrt_output_images[0] }}' '{{ inventory_hostname }}:/tmp/ansible-upgrade.img'"
- # - name: run sysupgrade
- # command: "ssh '{{ inventory_hostname }}' sysupgrade -n '/tmp/ansible-upgrade.img'"
- # ignore_errors: true
- # failed_when: false
- # register: sysupgrade_result
+ # - name: run sysupgrade
+ # command: "ssh '{{ inventory_hostname }}' sysupgrade -n '/tmp/ansible-upgrade.img'"
+ # ignore_errors: true
+ # failed_when: false
+ # register: sysupgrade_result
- # - debug:
- # var: sysupgrade_result.stdout
+ # - debug:
+ # var: sysupgrade_result.stdout
diff --git a/dan/info-beamer.yml b/dan/info-beamer.yml
index 3c9f65fe..272a2783 100644
--- a/dan/info-beamer.yml
+++ b/dan/info-beamer.yml
@@ -5,10 +5,10 @@
gather_facts: no
vars_prompt:
- - name: info_beamer_base_path
- prompt: Where is the SD-Card mounted to?
- default: ""
- private: no
+ - name: info_beamer_base_path
+ prompt: Where is the SD-Card mounted to?
+ default: ""
+ private: no
roles:
- - info-beamer/config
+ - role: info-beamer/config