opscode/knife-ec2 — pull request #97 by radekg (2013-03-13 17:00:00+00:00)
Title: Security groups support, no VPCs

Hi,
I have added following commands to the gem:

knife ec2 security group list
knife ec2 security group create -N name -D description
knife ec2 security group delete -G group-id
knife ec2 security group rule add -G group-id -P [tcp|udp|icmp] [-C cidr | -T target-group-id] -R [port|from-to]
knife ec2 security group rule delete -G group-id -P [tcp|udp|icmp] [-C cidr | -T target-group-id] -R [port|from-to]

There's no VPC support.

Example output:

tron:~ rad$ knife ec2 security group create -N "RadsTest" -D "RadsTest"
Name: RadsTest
Description: RadsTest
Group ID: sg-d7ab12a0
tron:~ rad$ knife ec2 security group rule add -G sg-d7ab12a0 -P tcp -C '0.0.0.0/0' -R 3000-4000
Name: RadsTest
Description: RadsTest
Group ID: sg-d7ab12a0
tron:~ rad$ knife ec2 security group rule delete -G sg-d7ab12a0 -P tcp -C '0.0.0.0/0' -R 3000-4000
Name: RadsTest
Description: RadsTest
Group ID: sg-d7ab12a0
tron:~ rad$ knife ec2 security group rule delete -G sg-d7ab12a0 -P tcp -C '0.0.0.0/0' -R 3000-4000
Name: RadsTest
Description: RadsTest
Group ID: sg-d7ab12a0
tron:~ rad$ knife ec2 security group delete -G sg-d7ab12a0
tron:~ rad$