Skip to content

Commit c0e9cc9

Browse files
committed
Update for GP3 Support
GP3 volume types are also SSD -- we should prefer those as well Signed-off-by: Brian Dwyer <[email protected]>
1 parent 00d3cc3 commit c0e9cc9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/kitchen/driver/aws/standard_platform.rb

+2-2
Original file line numberDiff line numberDiff line change
@@ -210,10 +210,10 @@ def sort_images(images)
210210
images = images.sort_by(&:creation_date).reverse
211211
# P5: We prefer x86_64 over i386 (if available)
212212
images = prefer(images) { |image| image.architecture == "x86_64" }
213-
# P4: We prefer gp2 (SSD) (if available)
213+
# P4: We prefer (SSD) (if available)
214214
images = prefer(images) do |image|
215215
image.block_device_mappings.any? do |b|
216-
b.device_name == image.root_device_name && b.ebs && b.ebs.volume_type == "gp2"
216+
b.device_name == image.root_device_name && b.ebs && %w{gp3 gp2}.any? { |t| b.ebs.volume_type == t }
217217
end
218218
end
219219
# P3: We prefer ebs over instance_store (if available)

0 commit comments

Comments
 (0)