mirror of
https://github.com/khuedoan/homelab.git
synced 2025-01-05 21:11:52 +07:00
Render Ignition JSON from Butane YAML
This commit is contained in:
parent
f1dc32c009
commit
ad75900e9c
@ -53,6 +53,22 @@
|
||||
dest: "{{ role_path }}/build/http/ignition/{{ hostvars[item]['mac'] }}.yaml"
|
||||
loop: "{{ groups['metal'] }}"
|
||||
|
||||
- name: Render Ignition config from Butane config
|
||||
docker_container:
|
||||
name: butane
|
||||
image: quay.io/coreos/butane:release
|
||||
auto_remove: yes
|
||||
volumes:
|
||||
- "{{ role_path }}/build/http/ignition:/local/src"
|
||||
working_dir: /local/src
|
||||
command:
|
||||
- --pretty
|
||||
- --strict
|
||||
- "{{ hostvars[item]['mac'] }}.yaml"
|
||||
- --output
|
||||
- "{{ hostvars[item]['mac'] }}.json"
|
||||
loop: "{{ groups['metal'] }}"
|
||||
|
||||
- name: Start ephemeral PXE server
|
||||
docker_compose:
|
||||
project_src: "{{ role_path }}/build"
|
||||
@ -61,4 +77,4 @@
|
||||
build: yes
|
||||
recreate: always
|
||||
notify:
|
||||
- Stop PXE server
|
||||
- Stop ephemeral PXE server
|
||||
|
@ -1,5 +1,6 @@
|
||||
variant: fcos
|
||||
version: 1.3.0
|
||||
|
||||
passwd:
|
||||
users:
|
||||
- name: core
|
||||
|
Loading…
Reference in New Issue
Block a user