boto_secgroup is using group's Name, not the usual tag:Name - breaking both execution (.run) and state (.instance_present) modules if Name and tag:Name are different #55337
Labels
boto
AWS wrapper modules
Bug
broken, incorrect, or confusing behavior
Confirmed
Salt engineer has confirmed bug/feature - often including a MCVE
severity-high
2nd top severity, seen by most users, causes major problems
Projects
Milestone
Description of Issue
So far, I've seen salt referring to tag:Name in its boto modules. I've had to figure out myself boto_secgroup is actually using the Name, not the usual tag:Name. For consistency, the tag:Name should be used to manage AWS Security groups. This has important consequences because this module is used by
boto_ec2.run
, which is turn used byboto_ec2.instance_present
. Basically if we're trying to use default SG's name ininstance_present
bith state and module will fail.This is Checking all Security groups, we see that every security group has a name, and a tag:Name. Usually, these are identical, but with the default group, the Name will be 'default' while the tag:Name will be the one we've defined.
If I try searching for the SG by using the tag name 'SG-NAT' instead of the Name 'default', salt returns nothing.
The following will return 'False' ('SG-NAT' is the tag Name of the default group)
This will instead successfully find the group's ID
For consistency with other modules, this module should only use tags.
Or at least this peculiarity should be documented..
Versions Report
The text was updated successfully, but these errors were encountered: