aws_security_viz 0.1.5.pre.alpha.pre.85 → 0.1.5.pre.alpha.pre.87
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/exe/aws_security_viz +1 -0
- data/lib/provider/ec2.rb +4 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 974122235ec3037bdcdb110926d303a543f39e1d
|
4
|
+
data.tar.gz: 586b684c7dcb19d5c3ff7e85bfe05d05df8531f4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 41d3356c232f3d8ce66cde360b2fb0088e9f6c654fb8ee328a26ece8d50d0ecd082afee13d9dfb3f4935ff795991be5bcb52d5dcddcba9d118475ec20b909728
|
7
|
+
data.tar.gz: 0453267a79009d5b5f083ac2c878ddf7988905091fc1c928498262b0527994f6803bb538c3c64e4077869e16bdd9ab114b283c9e5d92ce19830e692b6f62417c
|
data/exe/aws_security_viz
CHANGED
@@ -7,6 +7,7 @@ opts = Trollop::options do
|
|
7
7
|
opt :access_key, 'AWS access key', :default => ENV['AWS_ACCESS_KEY'] || ENV['AWS_ACCESS_KEY_ID'], :type => :string
|
8
8
|
opt :secret_key, 'AWS secret key', :default => ENV['AWS_SECRET_KEY'] || ENV['AWS_SECRET_ACCESS_KEY'], :type => :string
|
9
9
|
opt :region, 'AWS region to query', :default => 'us-east-1', :type => :string
|
10
|
+
opt :vpc_id, 'AWS VPC id to show', :type => :string
|
10
11
|
opt :source_file, 'JSON source file containing security groups', :type => :string
|
11
12
|
opt :filename, 'Output file name', :type => :string, :default => 'aws-security-viz.png'
|
12
13
|
opt :config, 'Config file (opts.yml)', :type => :string, :default => 'opts.yml'
|
data/lib/provider/ec2.rb
CHANGED
@@ -3,6 +3,7 @@ require 'fog/aws'
|
|
3
3
|
class Ec2Provider
|
4
4
|
|
5
5
|
def initialize(options)
|
6
|
+
@options = options
|
6
7
|
conn_opts = {
|
7
8
|
region: options[:region]
|
8
9
|
}
|
@@ -14,7 +15,9 @@ class Ec2Provider
|
|
14
15
|
end
|
15
16
|
|
16
17
|
def security_groups
|
17
|
-
@compute.security_groups.
|
18
|
+
@compute.security_groups.reject { |sg|
|
19
|
+
@options[:vpc_id] && sg.vpc_id != @options[:vpc_id]
|
20
|
+
}.collect { |sg|
|
18
21
|
Ec2::SecurityGroup.new(sg)
|
19
22
|
}
|
20
23
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws_security_viz
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.5.pre.alpha.pre.
|
4
|
+
version: 0.1.5.pre.alpha.pre.87
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Anay Nayak
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-09-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -259,7 +259,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
259
259
|
version: 1.3.1
|
260
260
|
requirements: []
|
261
261
|
rubyforge_project:
|
262
|
-
rubygems_version: 2.
|
262
|
+
rubygems_version: 2.6.13
|
263
263
|
signing_key:
|
264
264
|
specification_version: 4
|
265
265
|
summary: Visualize your aws security groups
|