Skip to content

Commit

Permalink
fix ubuntu cloud-init
Browse files Browse the repository at this point in the history
  • Loading branch information
goffinet committed Oct 19, 2024
1 parent 9724057 commit a0d51f9
Show file tree
Hide file tree
Showing 13 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion almalinux9.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

variable "config_file" {
type = string
Expand Down
2 changes: 1 addition & 1 deletion centos9.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

variable "config_file" {
type = string
Expand Down
2 changes: 1 addition & 1 deletion fedora40.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

variable "config_file" {
type = string
Expand Down
2 changes: 1 addition & 1 deletion http/almalinux9-kickstart.cfg
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

#auth --enableshadow --passalgo=sha512
url --url="https://repo.almalinux.org/almalinux/9.4/BaseOS/x86_64/kickstart/"
Expand Down
2 changes: 1 addition & 1 deletion http/centos9-kickstart.cfg
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

#auth --enableshadow --passalgo=sha512
url --url="https://mirror.stream.centos.org/9-stream/BaseOS/x86_64/os"
Expand Down
2 changes: 1 addition & 1 deletion http/fedora40-kickstart.cfg
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

#auth --enableshadow --passalgo=sha512
url --url="https://fedora.cu.be/linux/releases/40/Server/x86_64/os"
Expand Down
4 changes: 2 additions & 2 deletions http/ubuntu2004/user-data
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

#cloud-config
autoinstall:
version: 1
identity:
hostname: ubuntu2004
username: ubuntu
password: $6$rounds=4096$NjttGeGAb4Y7Q4i4$mbQYYtpj.7C/Sw7Tau1HFsfeZE3hFLvOBIUHg1dzlpcfh/H9.q2yHO7m2eCgueA9hhDBhmYvsUTeE8EFfw7kr1
password: $6$rounds=4096$oqGACZg/okV0CL8w$SBDD9yaOZ0ZbafbgIfCTlykdTmsNd9glV3BCn9HF5kP0hpHbuiejIIMZYh1pVW/cyIJ3wKa0ONxLau11eOkGW0
user-data:
disable_root: false
keyboard:
Expand Down
4 changes: 2 additions & 2 deletions http/ubuntu2204/user-data
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

#cloud-config
autoinstall:
version: 1
identity:
hostname: ubuntu2204
username: ubuntu
password: $6$rounds=4096$hEJN9vCOjRIpOGzt$.qwqHkmugVO7b0KgIGyn9zDaghGvsxge7cUiJbjugPsnUEW8JNnnjtAUArla3teXmqEr2fF8kFcMLERgsWPd10
password: $6$rounds=4096$J/PIZ9pzOve4HYL.$N5.bBokrODtL/1UPW.A.gXy1MHYpVUgt7ZTy.JpgYOhqk8M0Bp9/ARHLWUNOpJGNnPqY9cdumUAdfg0fA0usO1
user-data:
disable_root: false
keyboard:
Expand Down
4 changes: 2 additions & 2 deletions http/ubuntu2404/user-data
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

#cloud-config
autoinstall:
version: 1
identity:
hostname: ubuntu2404
username: ubuntu
password: $6$rounds=4096$//7LlSEkkL3sfP5d$X1I7B7HWtXGx8hFwoJpTRRKuXjz2IVtJb.QbX6qPVMGPNoNE7EcIapNtCf16IA.ombc3p7Q45hm9bgFSnU5NB0
password: $6$rounds=4096$RmxDdr3OZpOwbGAj$7zWC6sQxaKISAmRUW.yZvUony68V6D3rWixZ0MM/zzY6PuTCvTTSL.Gdy.TyVkeuY9tU4XKuPGMUPTBmvAMvp0
user-data:
disable_root: false
keyboard:
Expand Down
2 changes: 1 addition & 1 deletion roles/build-packer-templates/defaults/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ debian:
ubuntu2004:
boot_command: '["<enter><enter><f6><esc><wait>", "<bs><bs><bs><bs>", "autoinstall net.ifnames=0 biosdevname=0 ip=dhcp ipv6.disable=1 ds=nocloud-net;s=http://{% raw %}{{ .HTTPIP }}:{{ .HTTPPort }}/http/${var.config_file}{% endraw %}/ ", "--- <enter>"]'
ubuntu2204:
boot_command: '["c<wait>linux /casper/vmlinuz --- autoinstall ds=nocloud-net;seedfrom=http://{% raw %}{{ .HTTPIP }}:{{ .HTTPPort }}/http/${var.name}${var.version}/${var.config_file}{% endraw %}<enter><wait>", "initrd /casper/initrd<enter><wait>", "boot<enter><wait>"]'
boot_command: '["c<wait>linux /casper/vmlinuz --- autoinstall {% raw %}ds="nocloud;s=http://{{ .HTTPIP }}:{{ .HTTPPort }}/http/${var.name}${var.version}/${var.config_file}"{% endraw %}<enter><wait>", "initrd /casper/initrd<enter><wait>", "boot<enter><wait>"]'
ubuntu2404:
boot_command: '["<esc><esc><esc><esc>e<wait>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "<del><del><del><del><del><del><del><del>", "linux /casper/vmlinuz --- autoinstall ds=\"nocloud-net;seedfrom=http://{% raw %}{{ .HTTPIP }}:{{ .HTTPPort }}/http/${var.config_file}{% endraw %}/\"<enter><wait>", "initrd /casper/initrd<enter><wait>", "boot<enter>", "<enter><f10><wait>"]'
shell_provisioner: '["sudo apt-get update", "sudo apt-get -y install software-properties-common", "sudo apt-add-repository --yes --update ppa:ansible/ansible", "sudo apt update", "sudo apt -y install ansible"]'
Expand Down
2 changes: 1 addition & 1 deletion ubuntu2004.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

variable "config_file" {
type = string
Expand Down
4 changes: 2 additions & 2 deletions ubuntu2204.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

variable "config_file" {
type = string
Expand Down Expand Up @@ -62,7 +62,7 @@ variable "version" {

source "qemu" "ubuntu2204" {
accelerator = "kvm"
boot_command = ["c<wait>linux /casper/vmlinuz --- autoinstall ds=nocloud-net;seedfrom=http://{{ .HTTPIP }}:{{ .HTTPPort }}/http/${var.name}${var.version}/${var.config_file}<enter><wait>", "initrd /casper/initrd<enter><wait>", "boot<enter><wait>"]
boot_command = ["c<wait>linux /casper/vmlinuz --- autoinstall ds=\"nocloud;s=http://{{ .HTTPIP }}:{{ .HTTPPort }}/http/${var.name}${var.version}/${var.config_file}"<enter><wait>", "initrd /casper/initrd<enter><wait>", "boot<enter><wait>"]
disk_cache = "none"
disk_compression = true
disk_discard = "unmap"
Expand Down
2 changes: 1 addition & 1 deletion ubuntu2404.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:28:48Z
#Generated by packer-kvm/build-packer-templates.yaml at 2024-10-19T13:47:07Z

variable "config_file" {
type = string
Expand Down

0 comments on commit a0d51f9

Please sign in to comment.