forked from notthebee/infra
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
user-data is now generated from a template
- Loading branch information
Showing
6 changed files
with
61 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
/ansible/files/docker_persistent_data/* | ||
!/ansible/files/docker_persistent_data/.gitkeep | ||
cloud-init/user-data | ||
/ansible/group_vars/fragile | ||
/ansible/hosts | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
- hosts: all | ||
gather_facts: no | ||
|
||
tasks: | ||
- name: Generate the user-data | ||
delegate_to: localhost | ||
template: | ||
src: user-data.j2 | ||
dest: ../cloud-init/user-data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#cloud-config | ||
autoinstall: | ||
version: 1 | ||
locale: {{ locale }} | ||
keyboard: | ||
layout: {{ keyboard_layout }} | ||
identity: | ||
hostname: {{ hostname }} | ||
password: {{ password | password_hash('sha512') }} | ||
username: {{ username }} | ||
network: | ||
network: | ||
version: 2 | ||
ethernets: | ||
enp1s0: | ||
critical: true | ||
dhcp-identifier: mac | ||
dhcp4: true | ||
ssh: | ||
install-server: true | ||
authorized-keys: [ {{ ssh_public_key }} ] | ||
storage: | ||
grub: | ||
reorder_uefi: False | ||
swap: | ||
size: 0 | ||
config: | ||
- {ptable: gpt, serial: {{ boot_drive_serial }}, preserve: false, name: '', grub_device: false, type: disk, id: bootdrive} | ||
|
||
- {device: bootdrive, size: 536870912, wipe: superblock, flag: boot, number: 1, preserve: false, grub_device: true, type: partition, id: efipart} | ||
- {fstype: fat32, volume: efipart, preserve: false, type: format, id: efi} | ||
|
||
- {device: bootdrive, size: -1, wipe: superblock, flag: linux, number: 2, preserve: false, grub_device: false, type: partition, id: rootpart} | ||
- {fstype: ext4, volume: rootpart, preserve: false, type: format, id: root} | ||
|
||
- {device: root, path: /, type: mount, id: rootmount} | ||
- {device: efi, path: /boot/efi, type: mount, id: efimount} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
#cloud-config | ||
autoinstall: | ||
version: 1 | ||
locale: en_us.UTF-8 | ||
locale: en-us.UTF-8 | ||
keyboard: | ||
layout: us | ||
identity: | ||
hostname: fragile | ||
password: "$1$xyz$7ujQcnF8S3A6JQDF2fcsc/" | ||
password: $6$cOn46nlsDBIIErKf$J5ZUpmNC8fGwgkplxj8evLN5sIYTPWnuK5THBYkVBvzlfsH58uVbpwrBxfvvoU9CB1g4JpvWwRZW6P33I/jXB/ | ||
username: notthebee | ||
network: | ||
network: | ||
|
@@ -18,7 +18,7 @@ autoinstall: | |
dhcp4: true | ||
ssh: | ||
install-server: true | ||
authorized-keys: [ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKGUGMUo1dRl9xoDlMxQGb8dNSY+6xiEpbZWAu6FAbWw [email protected]" ] | ||
authorized-keys: [ ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKGUGMUo1dRl9xoDlMxQGb8dNSY+6xiEpbZWAu6FAbWw [email protected] ] | ||
storage: | ||
grub: | ||
reorder_uefi: False | ||
|