Method: AwsEc2Instance#security_groups
- Defined in:
- lib/resources/aws/aws_ec2_instance.rb
#security_groups ⇒ Object
Don’t document this - it’s a bit hard to use. Our current doctrine is to use dumb things, like arrays of strings - use security_group_ids instead.
117 118 119 120 121 122 123 |
# File 'lib/resources/aws/aws_ec2_instance.rb', line 117 def security_groups catch_aws_errors do @security_groups ||= instance.security_groups.map do |sg| { id: sg.group_id, name: sg.group_name } end end end |