Skip to content

Commit

Permalink
chore(ubuntu): Use pinned aws base AMI IDs from images-versions.yaml (
Browse files Browse the repository at this point in the history
#1472)

* feat(ubuntu):Pin ubuntu 22.04 AMI ids

Signed-off-by: jayfranco999 <[email protected]>

* fixup

Signed-off-by: jayfranco999 <[email protected]>

---------

Signed-off-by: jayfranco999 <[email protected]>
  • Loading branch information
jayfranco999 authored Oct 24, 2024
1 parent 6f5b550 commit c1cb5fd
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
2 changes: 1 addition & 1 deletion build-jenkins-agent-ubuntu.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build {
name = "ubuntu"
ssh_username = "ubuntu"
# Egg-and-chicken: what is the base image to start from (eg. what is my egg)?
source_ami = local.aws_ubuntu_amis[var.architecture]
source_ami = try(local.images_versions["aws"]["ubuntu"][var.agent_os_version][var.architecture], "N/A")
}

source "azure-arm.base" {
Expand Down
5 changes: 0 additions & 5 deletions locals.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@ locals {
"arm64" = "t4g.xlarge"
}
# TODO: track AMI versions with `updatecli`
# Uses aws ec2 describe-images to fetch the ami id as per the architecture
aws_ubuntu_amis = {
"amd64" = "ami-00eb69d236edcfaf8"
"arm64" = "ami-039e419d24a37cb82"
}
# List available SKUs with the command `az vm image list-skus --offer 0001-com-ubuntu-server-jammy --location eastus --publisher canonical --output table`
az_instance_image_sku = {
"amd64" = "${local.agent_os_version_safe}-lts-gen2"
Expand Down

0 comments on commit c1cb5fd

Please sign in to comment.