X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;ds=sidebyside;f=fdio.infra%2Fpacker-aws-sut%2Fubuntu_jammy_arm.pkr.hcl;fp=fdio.infra.packer%2Faws_c6gn%2Fubuntu_jammy.pkr.hcl;h=6e612f1fc4174b426f29cc9cbff2a9afb821120e;hb=efe51d995a9d736ce194dbd1c850d4a09e0a1506;hp=db2ce0c6e6c84e657473829d33fe6561fcf88526;hpb=192e1ac1f274d8eed3d33cdbc15fa995a74247c7;p=csit.git diff --git a/fdio.infra.packer/aws_c6gn/ubuntu_jammy.pkr.hcl b/fdio.infra/packer-aws-sut/ubuntu_jammy_arm.pkr.hcl similarity index 98% rename from fdio.infra.packer/aws_c6gn/ubuntu_jammy.pkr.hcl rename to fdio.infra/packer-aws-sut/ubuntu_jammy_arm.pkr.hcl index db2ce0c6e6..6e612f1fc4 100644 --- a/fdio.infra.packer/aws_c6gn/ubuntu_jammy.pkr.hcl +++ b/fdio.infra/packer-aws-sut/ubuntu_jammy_arm.pkr.hcl @@ -1,12 +1,12 @@ - packer { required_plugins { amazon = { - version = ">= 1.0.1" + version = ">= 1.2.6" source = "github.com/hashicorp/amazon" } } } + variable "first_run_commands" { description = "Commands to run before deployment via remote-exec" type = list(string) @@ -14,6 +14,7 @@ variable "first_run_commands" { "" ] } + variable "last_run_commands" { description = "Commands to run after deployment via remote-exec" type = list(string) @@ -21,26 +22,31 @@ variable "last_run_commands" { "sudo sed -i 's/Unattended-Upgrade \"1\"/Unattended-Upgrade \"0\"/g' /etc/apt/apt.conf.d/20auto-upgrades" ] } + variable "ansible_file_path" { description = "Path to Ansible playbook" type = string default = "../../fdio.infra.ansible/site.yaml" } + variable "ansible_python_executable" { description = "Path to Python interpreter" type = string default = "/usr/bin/python3" } + variable "ansible_topology_path" { description = "Path to Ansible playbook which creates a topology file" type = string default = "../../fdio.infra.ansible/cloud_topology.yaml" } + variable "ansible_provision_pwd" { description = "Password used for ansible provisioning (ansible_ssh_pass)" type = string default = "Csit1234" } + source "amazon-ebs" "csit_c6gn_ubuntu_jammy_sut" { ami_name = "csit_c6gn_ubuntu_jammy_sut" ami_description = "CSIT SUT image based on Ubuntu jammy" @@ -57,6 +63,7 @@ source "amazon-ebs" "csit_c6gn_ubuntu_jammy_sut" { source_ami = "ami-0a875db8a031a9efb" ssh_username = "ubuntu" } + source "amazon-ebs" "csit_c6gn_ubuntu_jammy_tg" { ami_name = "csit_c6gn_ubuntu_jammy_tg" ami_description = "CSIT TG image based on Ubuntu jammy" @@ -73,6 +80,7 @@ source "amazon-ebs" "csit_c6gn_ubuntu_jammy_tg" { source_ami = "ami-0a875db8a031a9efb" ssh_username = "ubuntu" } + build { name = "csit_c6gn_ubuntu_jammy_sut-packer" sources = [ @@ -95,6 +103,7 @@ build { inline = var.last_run_commands } } + build { name = "csit_c6gn_ubuntu_jammy_tg-packer" sources = [