cloud_former 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5655da92ae1e89903727fca0b2c3353fe684cf16
4
- data.tar.gz: 2baf41450d41bb9cf00994159a0383651089fe9d
3
+ metadata.gz: a4c8a68c6dbba764ed9592811f60b64d56937cd4
4
+ data.tar.gz: 809444c414974df80dc820771cf583a3233b4b22
5
5
  SHA512:
6
- metadata.gz: e450337ffe88aa9cc0a8b79f53fc085670ed51fb3dc7b146d4c8e6599e7b64b6a6e464a6b18c45cb8a8e7205dca793f459513a9d7aac59c54474c3d7c1049b15
7
- data.tar.gz: cb78971af9178b1ef4bed1cc252d84851b40162d2201392bc78ba92bc75782ad5056a80193426a897de9e2666107a68096b3bd0c53c51c66c7eafbd29192b621
6
+ metadata.gz: fb87d449d9242617c4d6622697243e2be3d66dc07636ad54528d897a98e271cb8a7aaee1f65d2628a31f74bdd27003a38f81f50894ce347ef10c4afc8954f912
7
+ data.tar.gz: fbb0e683f728e49d9b4c2af7e22bec64b81e298dad455fb6c3e5060a81a30047cdb09f6371125d16012db49b201a61190219a45422a8ecfda6a7b1e69ff89f5b
@@ -0,0 +1,9 @@
1
+ # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-sqs-queues-redrivepolicy.html
2
+ module CloudFormer
3
+ module SQS
4
+ class RedrivePolicy < ResourceProperty
5
+ aws_attribute :dead_letter_target_arn, name: 'deadLetterTargetArn', type: String
6
+ aws_attribute :max_receive_count, name: 'maxReceiveCount', type: Integer
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,9 @@
1
+ # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iam-instanceprofile.html
2
+ module CloudFormer
3
+ module IAM
4
+ class InstanceProfile < Resource
5
+ aws_property :path, type: String
6
+ aws_property :roles, list: true, type: Role
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,10 @@
1
+ # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iam-role.html
2
+ module CloudFormer
3
+ module IAM
4
+ class Role < Resource
5
+ aws_property :assume_role_policy_document, type: Hash
6
+ aws_property :path, type: String
7
+ aws_property :policies, list: true, type: Policy
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,9 @@
1
+ # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-addusertogroup.html
2
+ module CloudFormer
3
+ module IAM
4
+ class UserToGroupAddition < Resource
5
+ aws_property :group_name, type: String
6
+ aws_property :users, list: true, type: User
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,14 @@
1
+ # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-sqs-queues.html
2
+ module CloudFormer
3
+ module SQS
4
+ class Queue < Resource
5
+ aws_property :delay_seconds, type: Integer
6
+ aws_property :maximum_message_size, type: Integer
7
+ aws_property :message_retention_period, type: Integer
8
+ aws_property :queue_name, type: String
9
+ aws_property :receive_message_wait_time_seconds, type: Integer
10
+ aws_property :redrive_policy, embed: true, type: RedrivePolicy
11
+ aws_property :visibility_timeout, type: Integer
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,9 @@
1
+ # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-sqs-queues.html
2
+ module CloudFormer
3
+ module SQS
4
+ class QueuePolicy < Resource
5
+ aws_property :policy_document, type: Hash
6
+ aws_property :queues, type: String, list: true
7
+ end
8
+ end
9
+ end
@@ -1,3 +1,3 @@
1
1
  module CloudFormer
2
- VERSION = '0.2.1'
2
+ VERSION = '0.2.2'
3
3
  end
data/lib/cloud_former.rb CHANGED
@@ -145,8 +145,11 @@ module CloudFormer
145
145
  module IAM
146
146
  autoload :AccessKey, 'cloud_former/resources/iam/access_key'
147
147
  autoload :Group, 'cloud_former/resources/iam/group'
148
+ autoload :InstanceProfile, 'cloud_former/resources/iam/instance_profile'
148
149
  autoload :Policy, 'cloud_former/resources/iam/policy'
150
+ autoload :Role, 'cloud_former/resources/iam/role'
149
151
  autoload :User, 'cloud_former/resources/iam/user'
152
+ autoload :UserToGroupAddition, 'cloud_former/resources/iam/user_to_group_addition'
150
153
  end
151
154
 
152
155
  module RDS
@@ -180,6 +183,12 @@ module CloudFormer
180
183
  autoload :Topic, 'cloud_former/resources/sns/topic'
181
184
  end
182
185
 
186
+ module SQS
187
+ autoload :RedrivePolicy, 'cloud_former/resource_properties/sqs/redrive_policy'
188
+ autoload :Queue, 'cloud_former/resources/sqs/queue'
189
+ autoload :QueuePolicy, 'cloud_former/resources/sqs/queue_policy'
190
+ end
191
+
183
192
  autoload :AllAvailabilityZones, 'cloud_former/all_availability_zones'
184
193
  autoload :PropertyOrAttribute, 'cloud_former/property_or_attribute'
185
194
  autoload :Template, 'cloud_former/template'
@@ -0,0 +1,17 @@
1
+ require 'spec_helper'
2
+
3
+ describe CloudFormer::AutoScaling::UpdatePolicy do
4
+
5
+ let(:param) { CloudFormer::StringParameter.new('woot') }
6
+
7
+ let(:policy) do
8
+ p = param
9
+ CloudFormer::AutoScaling::UpdatePolicy.new do
10
+ max_batch_size p
11
+ end
12
+ end
13
+
14
+ it 'should make correct json' do
15
+ expect(policy.dump_json).to eq('')
16
+ end
17
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cloud_former
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aubrey Holland
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-01 00:00:00.000000000 Z
11
+ date: 2014-08-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -169,6 +169,7 @@ files:
169
169
  - lib/cloud_former/resource_properties/s3/website_configuration_routing_rules_redirect_rule.rb
170
170
  - lib/cloud_former/resource_properties/s3/website_configuration_routing_rules_routing_rule_condition.rb
171
171
  - lib/cloud_former/resource_properties/sns/subscription.rb
172
+ - lib/cloud_former/resource_properties/sqs/redrive_policy.rb
172
173
  - lib/cloud_former/resources/auto_scaling/auto_scaling_group.rb
173
174
  - lib/cloud_former/resources/auto_scaling/launch_configuration.rb
174
175
  - lib/cloud_former/resources/auto_scaling/scaling_policy.rb
@@ -211,8 +212,11 @@ files:
211
212
  - lib/cloud_former/resources/elastic_load_balancing/load_balancer.rb
212
213
  - lib/cloud_former/resources/iam/access_key.rb
213
214
  - lib/cloud_former/resources/iam/group.rb
215
+ - lib/cloud_former/resources/iam/instance_profile.rb
214
216
  - lib/cloud_former/resources/iam/policy.rb
217
+ - lib/cloud_former/resources/iam/role.rb
215
218
  - lib/cloud_former/resources/iam/user.rb
219
+ - lib/cloud_former/resources/iam/user_to_group_addition.rb
216
220
  - lib/cloud_former/resources/rds/db_instance.rb
217
221
  - lib/cloud_former/resources/rds/db_parameter_group.rb
218
222
  - lib/cloud_former/resources/rds/db_security_group.rb
@@ -220,6 +224,8 @@ files:
220
224
  - lib/cloud_former/resources/resource.rb
221
225
  - lib/cloud_former/resources/s3/bucket.rb
222
226
  - lib/cloud_former/resources/sns/topic.rb
227
+ - lib/cloud_former/resources/sqs/queue.rb
228
+ - lib/cloud_former/resources/sqs/queue_policy.rb
223
229
  - lib/cloud_former/template.rb
224
230
  - lib/cloud_former/version.rb
225
231
  - spec/metadata_spec.rb
@@ -233,6 +239,7 @@ files:
233
239
  - spec/spec_helper.rb
234
240
  - spec/template_spec.rb
235
241
  - spec/type_enforcement.rb
242
+ - spec/update_policy_spec.rb
236
243
  homepage: http://github.com/custora/cloud_former
237
244
  licenses:
238
245
  - MIT
@@ -269,4 +276,5 @@ test_files:
269
276
  - spec/spec_helper.rb
270
277
  - spec/template_spec.rb
271
278
  - spec/type_enforcement.rb
279
+ - spec/update_policy_spec.rb
272
280
  has_rdoc: