diff --git a/src/install-prerequisites-for-netplan-configuration-fix.yml b/src/install-prerequisites-for-netplan-configuration-fix.yml new file mode 100644 index 00000000..1c86cbcb --- /dev/null +++ b/src/install-prerequisites-for-netplan-configuration-fix.yml @@ -0,0 +1,21 @@ +--- +# Install the prerequisites for the user script that fixes the Netplan +# configuration generated by cloud-init from the instance metadata. +# +# See these issues for more details: +# - cisagov/skeleton-packer#300 +# - canonical/cloud-init#4764 +# +# TODO: Remove this playbook when and if that becomes possible. See +# cisagov/skeleton-packer#301 for more details. +- name: >- + Install prerequisites for the script that fixes the Netplan + configuration generated by cloud-init from the instance metadata + hosts: all + become: true + become_method: ansible.builtin.sudo + tasks: + - name: Install python3-pyyaml + ansible.builtin.package: + name: + - python3-yaml diff --git a/src/packer.pkr.hcl b/src/packer.pkr.hcl index cce1c942..849c29d8 100644 --- a/src/packer.pkr.hcl +++ b/src/packer.pkr.hcl @@ -63,9 +63,9 @@ variable "skip_create_ami" { type = bool } -data "amazon-ami" "debian_bullseye" { +data "amazon-ami" "debian_bookworm" { filters = { - name = "debian-11-amd64-*" + name = "debian-12-amd64-*" root-device-type = "ebs" virtualization-type = "hvm" } @@ -93,7 +93,7 @@ source "amazon-ebs" "example" { region = var.build_region region_kms_key_ids = var.region_kms_keys skip_create_ami = var.skip_create_ami - source_ami = data.amazon-ami.debian_bullseye.id + source_ami = data.amazon-ami.debian_bookworm.id ssh_username = "admin" subnet_filter { filters = { @@ -102,9 +102,9 @@ source "amazon-ebs" "example" { } tags = { Application = "Example" - Base_AMI_Name = data.amazon-ami.debian_bullseye.name + Base_AMI_Name = data.amazon-ami.debian_bookworm.name GitHub_Release_URL = var.release_url - OS_Version = "Debian Bullseye" + OS_Version = "Debian Bookworm" Pre_Release = var.is_prerelease Release = var.release_tag Team = "VM Fusion - Development" diff --git a/src/playbook.yml b/src/playbook.yml index b1e5b7cd..703a7deb 100644 --- a/src/playbook.yml +++ b/src/playbook.yml @@ -2,6 +2,13 @@ - name: Import base image playbook ansible.builtin.import_playbook: base.yml +# TODO: Remove this when and if that becomes possible. See +# cisagov/skeleton-packer#301. +- name: >- + Import playbook to install prerequisites for the Netplan + configuration fix + ansible.builtin.import_playbook: install-prerequisites-for-netplan-configuration-fix.yml + - name: Import AWS playbook ansible.builtin.import_playbook: aws.yml diff --git a/src/version.txt b/src/version.txt index 1acb7e39..5becc17c 100644 --- a/src/version.txt +++ b/src/version.txt @@ -1 +1 @@ -__version__ = "1.0.0-rc.2" +__version__ = "1.0.0"