mirror of
https://github.com/khuedoan/homelab.git
synced 2025-01-05 21:11:52 +07:00
Use template for Butane configs
This commit is contained in:
parent
0157d25093
commit
f1dc32c009
@ -47,15 +47,10 @@
|
||||
src: tftp/tftpboot/grub.cfg.j2
|
||||
dest: "{{ role_path }}/build/tftp/tftpboot/grub.cfg"
|
||||
|
||||
- name: Render shared kickstart config
|
||||
- name: Render machine specific Butane config
|
||||
template:
|
||||
src: http/kickstart/fedora.ks.j2
|
||||
dest: "{{ role_path }}/build/http/kickstart/fedora.ks"
|
||||
|
||||
- name: Render seperate network kickstart config for each node
|
||||
template:
|
||||
src: http/kickstart/network/network.ks.j2
|
||||
dest: "{{ role_path }}/build/http/kickstart/network/{{ hostvars[item]['mac'] }}.ks"
|
||||
src: http/ignition/ignition.yaml
|
||||
dest: "{{ role_path }}/build/http/ignition/{{ hostvars[item]['mac'] }}.yaml"
|
||||
loop: "{{ groups['metal'] }}"
|
||||
|
||||
- name: Start ephemeral PXE server
|
||||
|
@ -4,7 +4,7 @@ passwd:
|
||||
users:
|
||||
- name: core
|
||||
ssh_authorized_keys:
|
||||
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBbqNJWKwLmwkeHQVUVT/pEis/wvRqRSKG9Dpl166NGp # TODO template
|
||||
- {{ ssh_public_key }}
|
||||
|
||||
storage:
|
||||
# Set hostname
|
||||
@ -12,7 +12,7 @@ storage:
|
||||
- path: /etc/hostname
|
||||
mode: 0644
|
||||
contents:
|
||||
inline: metal3 # TODO template
|
||||
inline: {{ hostvars[item]['inventory_hostname'] }}
|
||||
# Set timezone
|
||||
links:
|
||||
- path: /etc/localtime
|
||||
|
Loading…
Reference in New Issue
Block a user