Skip to content

Commit

Permalink
Merge pull request #314 from gildub/instance_prov-allow-disk-0
Browse files Browse the repository at this point in the history
Instances workflow: Allow flavors with disk size of 0
  • Loading branch information
mansam authored Jul 12, 2018
2 parents 13732ff + 2656bd1 commit 5598b27
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ def allowed_instance_types(_options = {})
minimum_memory_required = source.hardware.memory_mb_minimum.to_i * 1.megabyte
end
flavors.each_with_object({}) do |flavor, h|
next if flavor.root_disk_size < minimum_disk_required
# Allow flavors with 0 disk size: The instance will grow disk based upon image build definition
next if flavor.root_disk_size.positive? && flavor.root_disk_size < minimum_disk_required
next if flavor.memory < minimum_memory_required
h[flavor.id] = display_name_for_name_description(flavor)
end
Expand Down

0 comments on commit 5598b27

Please sign in to comment.