Skip to content

Commit

Permalink
Decouple EBS CSI driver version from ECS Agent version
Browse files Browse the repository at this point in the history
  • Loading branch information
chienhanlin committed Nov 28, 2023
1 parent 0ac9ca7 commit d2592cb
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions al2.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ build {
environment_vars = [
"REGION=${var.region}",
"AGENT_VERSION=${var.ecs_agent_version}",
"EBS_CSI_DRIVER_VERSION=${var.ebs_csi_driver_version}",
"AIR_GAPPED=${var.air_gapped}",
"MANAGED_DAEMON_BASE_URL=${var.managed_daemon_base_url}"
]
Expand Down
1 change: 1 addition & 0 deletions al2023.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ build {
environment_vars = [
"REGION=${var.region}",
"AGENT_VERSION=${var.ecs_agent_version}",
"EBS_CSI_DRIVER_VERSION=${var.ebs_csi_driver_version}",
"AIR_GAPPED=${var.air_gapped}",
"MANAGED_DAEMON_BASE_URL=${var.managed_daemon_base_url}"
]
Expand Down
1 change: 1 addition & 0 deletions generate-release-vars.sh
Original file line number Diff line number Diff line change
Expand Up @@ -91,4 +91,5 @@ source_ami_al2023arm = "$ami_name_al2023_arm"
kernel_version_al2023 = "$kernel_version_al2023_x86"
kernel_version_al2023arm = "$kernel_version_al2023_arm"
distribution_release_al2023 = "$distribution_release_al2023"
ebs_csi_driver_version = "$agent_version"
EOF
2 changes: 1 addition & 1 deletion scripts/install-managed-daemons.sh
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ case "$ARCH" in
esac

# Install CSI driver managed daemon
CSI_DRIVER_FILENAME="ebs-csi-driver${ARCH_MOD}-v$AGENT_VERSION.tar"
CSI_DRIVER_FILENAME="ebs-csi-driver${ARCH_MOD}-v${EBS_CSI_DRIVER_VERSION}.tar"
CSI_DRIVER_FULL_URL="${MANAGED_DAEMON_BASE_URL}${CSI_DRIVER_FILENAME}"

curl -fLSs -o "$WORK_DIR/${CSI_DRIVER_FILENAME}" "$CSI_DRIVER_FULL_URL"
Expand Down
5 changes: 5 additions & 0 deletions variables.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -210,3 +210,8 @@ variable "managed_daemon_base_url" {
description = "Base URL (minus file name) to download managed daemons from."
default = ""
}

variable "ebs_csi_driver_version" {
type = string
description = "EBS CSI driver version to build AMI with."
}

0 comments on commit d2592cb

Please sign in to comment.