piculet 0.2.5 → 0.2.6.beta
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/bin/piculet +12 -1
- data/lib/piculet/client.rb +2 -1
- data/lib/piculet/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ddcd012f4f13f2f3426ef922c2cd8e6551398880
|
|
4
|
+
data.tar.gz: efe06333d02bcef32e18f772f5911a046901d95a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: f5e7c94ce0ed188ce0dc0aaa33900a913c9f16aa1f976b142e82f016fb33f8c8304be54de173942aad558a96fc3f2e37afa0f38d82607965563d9d0ef43a213a
|
|
7
|
+
data.tar.gz: 3111161d7cbe0604e77019259d71dacaaf3fbaafaff33f4b1c8f17ba2e3cca0eeca911d75a576597f029a0362b87fa4b8f229fe437fec25f0714d4e02e9476bf
|
data/bin/piculet
CHANGED
|
@@ -10,6 +10,10 @@ mode = nil
|
|
|
10
10
|
file = 'Groupfile'
|
|
11
11
|
output_file = '-'
|
|
12
12
|
split = false
|
|
13
|
+
MAGIC_COMMENT = <<-EOS
|
|
14
|
+
# -*- mode: ruby -*-
|
|
15
|
+
# vi: set ft=ruby :
|
|
16
|
+
EOS
|
|
13
17
|
|
|
14
18
|
options = {
|
|
15
19
|
:dry_run => false,
|
|
@@ -97,6 +101,7 @@ begin
|
|
|
97
101
|
logger.info(" write `#{group_file}`")
|
|
98
102
|
|
|
99
103
|
open(group_file, 'wb') do |f|
|
|
104
|
+
f.puts MAGIC_COMMENT
|
|
100
105
|
f.puts converter.call(vpc => security_groups)
|
|
101
106
|
end
|
|
102
107
|
end
|
|
@@ -105,6 +110,8 @@ begin
|
|
|
105
110
|
logger.info(" write `#{output_file}`")
|
|
106
111
|
|
|
107
112
|
open(output_file, 'wb') do |f|
|
|
113
|
+
f.puts MAGIC_COMMENT
|
|
114
|
+
|
|
108
115
|
requires.each do |group_file|
|
|
109
116
|
f.puts "require '#{File.basename group_file}'"
|
|
110
117
|
end
|
|
@@ -115,7 +122,11 @@ begin
|
|
|
115
122
|
puts client.export(options)
|
|
116
123
|
else
|
|
117
124
|
logger.info("Export SecurityGroup to `#{output_file}`")
|
|
118
|
-
|
|
125
|
+
|
|
126
|
+
open(output_file, 'wb') do |f|
|
|
127
|
+
f.puts MAGIC_COMMENT
|
|
128
|
+
f.puts client.export(options)
|
|
129
|
+
end
|
|
119
130
|
end
|
|
120
131
|
end
|
|
121
132
|
when :apply
|
data/lib/piculet/client.rb
CHANGED
|
@@ -4,6 +4,7 @@ module Piculet
|
|
|
4
4
|
|
|
5
5
|
def initialize(options = {})
|
|
6
6
|
@options = OpenStruct.new(options)
|
|
7
|
+
@options_hash = options
|
|
7
8
|
@options.ec2 = AWS::EC2.new
|
|
8
9
|
end
|
|
9
10
|
|
|
@@ -14,7 +15,7 @@ module Piculet
|
|
|
14
15
|
|
|
15
16
|
def export(options = {})
|
|
16
17
|
exported = AWS.memoize do
|
|
17
|
-
Exporter.export(@options.ec2, options)
|
|
18
|
+
Exporter.export(@options.ec2, @options_hash.merge(options))
|
|
18
19
|
end
|
|
19
20
|
|
|
20
21
|
if block_given?
|
data/lib/piculet/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: piculet
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.6.beta
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- winebarrel
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2014-
|
|
11
|
+
date: 2014-12-07 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: aws-sdk
|
|
@@ -146,9 +146,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
146
146
|
version: '0'
|
|
147
147
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
148
148
|
requirements:
|
|
149
|
-
- - '
|
|
149
|
+
- - '>'
|
|
150
150
|
- !ruby/object:Gem::Version
|
|
151
|
-
version:
|
|
151
|
+
version: 1.3.1
|
|
152
152
|
requirements: []
|
|
153
153
|
rubyforge_project:
|
|
154
154
|
rubygems_version: 2.0.14
|