From 3882ccbaf8789d13357c926b286f106d31950792 Mon Sep 17 00:00:00 2001 From: Andrew Grimberg Date: Thu, 10 Jun 2021 13:05:27 -0700 Subject: [PATCH] Fix: AMI product codes need to be defined While trying to upgrade the internal Jenkins to latest global-jjb and common-packer it's been found that all of our configurations for AWS systems are missing vital filters. The Ubuntu product codes were found by doing the following: aws ec2 describe-images --region us-west-2 \ --owners aws-marketplace --filters \ "Name=architecture,Values=arm64" \ "Name=name,Values=*ubuntu*20.04*" \ "Name=manifest-location,Values=aws-marketplace/ubuntu/*" This is per documentation found at https://ubuntu.com/server/docs/cloud-images/amazon-ec2 Issue: RELENG-3757 Change-Id: I9391f6bec59318e00bc1b097c7a27181defeccff Signed-off-by: Andrew Grimberg --- releasenotes/notes/ami_product_codes-162e88f3d82e9679.yaml | 5 +++++ vars/centos-7-arm64.json | 5 +++-- vars/ubuntu-16.04-arm64.json | 3 ++- vars/ubuntu-18.04-arm64.json | 3 ++- vars/ubuntu-20.04-arm64.json | 3 ++- vars/ubuntu-20.04.json | 3 ++- vars/windows-server-2016.json | 1 + 7 files changed, 17 insertions(+), 6 deletions(-) create mode 100644 releasenotes/notes/ami_product_codes-162e88f3d82e9679.yaml diff --git a/releasenotes/notes/ami_product_codes-162e88f3d82e9679.yaml b/releasenotes/notes/ami_product_codes-162e88f3d82e9679.yaml new file mode 100644 index 0000000..3787760 --- /dev/null +++ b/releasenotes/notes/ami_product_codes-162e88f3d82e9679.yaml @@ -0,0 +1,5 @@ +--- +fixes: + - | + All vars files have been updated to properly include the AMI product code + filter. This is needed to properly pass global-jjb verification. diff --git a/vars/centos-7-arm64.json b/vars/centos-7-arm64.json index e86dff0..3eeb6ce 100644 --- a/vars/centos-7-arm64.json +++ b/vars/centos-7-arm64.json @@ -5,7 +5,8 @@ "distro": "CentOS 7", "docker_source_image": "arm64v8/centos:7", "flavor": "v3-standard-2", - "source_ami_filter_name": "*CentOS Linux 7*HVM*", - "source_ami_filter_owner": "679593333241", + "source_ami_filter_name": "*CentOS 7*aarch64*", + "source_ami_filter_owner": "aws-marketplace", + "source_ami_filter_product_code": "6zber5dti4jyo9khb62tg49o8", "ssh_user": "centos" } diff --git a/vars/ubuntu-16.04-arm64.json b/vars/ubuntu-16.04-arm64.json index d591eaa..ea877a0 100644 --- a/vars/ubuntu-16.04-arm64.json +++ b/vars/ubuntu-16.04-arm64.json @@ -6,6 +6,7 @@ "docker_source_image": "arm64v8/ubuntu:16.04", "flavor": "v3-standard-2", "source_ami_filter_name": "*ubuntu*16.04*", - "source_ami_filter_owner": "099720109477", + "source_ami_filter_owner": "aws-marketplace", + "source_ami_filter_product_code": "7x1es1d2cyv0hf36v5nqpcp32", "ssh_user": "ubuntu" } diff --git a/vars/ubuntu-18.04-arm64.json b/vars/ubuntu-18.04-arm64.json index d250a0b..1050727 100644 --- a/vars/ubuntu-18.04-arm64.json +++ b/vars/ubuntu-18.04-arm64.json @@ -6,6 +6,7 @@ "docker_source_image": "arm64v8/ubuntu:18.04", "flavor": "v3-standard-2", "source_ami_filter_name": "*ubuntu*18.04*", - "source_ami_filter_owner": "099720109477", + "source_ami_filter_owner": "aws-marketplace", + "source_ami_filter_product_code": "zud1u4kjmxu2j2jf0n36beqt", "ssh_user": "ubuntu" } diff --git a/vars/ubuntu-20.04-arm64.json b/vars/ubuntu-20.04-arm64.json index 338d904..b27ce59 100644 --- a/vars/ubuntu-20.04-arm64.json +++ b/vars/ubuntu-20.04-arm64.json @@ -6,6 +6,7 @@ "docker_source_image": "arm64v8/ubuntu:20.04", "flavor": "v3-standard-2", "source_ami_filter_name": "*ubuntu*20.04*", - "source_ami_filter_owner": "099720109477", + "source_ami_filter_owner": "aws-marketplace", + "source_ami_filter_product_code": "3j3t5wgc6orwshxai7wk5sux9", "ssh_user": "ubuntu" } diff --git a/vars/ubuntu-20.04.json b/vars/ubuntu-20.04.json index 17c67b4..a0c2342 100644 --- a/vars/ubuntu-20.04.json +++ b/vars/ubuntu-20.04.json @@ -1,6 +1,7 @@ { "source_ami_filter_name": "*ubuntu*20.04*", - "source_ami_filter_owner": "099720109477", + "source_ami_filter_owner": "aws-marketplace", + "source_ami_filter_product_code": "a8jyynf4hjutohctm41o2z18m", "base_image": "LF - Ubuntu 20.04 LTS (2020-08-04)", "distro": "Ubuntu 20.04", "docker_source_image": "ubuntu:20.04", diff --git a/vars/windows-server-2016.json b/vars/windows-server-2016.json index d30a01f..53b3842 100644 --- a/vars/windows-server-2016.json +++ b/vars/windows-server-2016.json @@ -1,6 +1,7 @@ { "source_ami_filter_name": "", "source_ami_filter_owner": "", + "source_ami_filter_product_code": "", "base_image": "Windows Server Standard 2016 [2017-02-20]", "distro": "Windows 2016", "docker_source_image": "windows:2016", -- 2.16.6