You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The AssertEC2InstancesBalancedInSubnets in the aws package was built with the assumption that (quoted from the method docs): "instance number 'x' in the [list of instances provided] should be placed in the subnet with an index of 'x modulus the length of the [subnet list provided]'". As it turns out, depending on a number of factors such as the subnet or instance IDs assigned to resources, launch time of instances, etc, this is likely not a valid assumption of consistent behavior from Terraform or other infrastructure providers.
The method needs to be rewritten to use a more algorithmic approach to ensuring that instances in a given list are appropriately spread between the unique list of subnets of all instances in the list, such that no one subnet has more than math.floor(# of instances / # of subnets) instances placed in it.
The text was updated successfully, but these errors were encountered:
The
AssertEC2InstancesBalancedInSubnets
in theaws
package was built with the assumption that (quoted from the method docs): "instance number 'x' in the [list of instances provided] should be placed in the subnet with an index of 'x modulus the length of the [subnet list provided]'". As it turns out, depending on a number of factors such as the subnet or instance IDs assigned to resources, launch time of instances, etc, this is likely not a valid assumption of consistent behavior from Terraform or other infrastructure providers.The method needs to be rewritten to use a more algorithmic approach to ensuring that instances in a given list are appropriately spread between the unique list of subnets of all instances in the list, such that no one subnet has more than
math.floor(# of instances / # of subnets)
instances placed in it.The text was updated successfully, but these errors were encountered: