awsclient 0.1.1 → 0.1.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b93e91331dc38ac767656b0fd29df85149a1e004
4
- data.tar.gz: cd6d8c8b2c46f8e9866f4defd5d335792a87ed06
3
+ metadata.gz: 77158934d6c2e85aabcdb181eca49f95d96086d4
4
+ data.tar.gz: c660c48023d7a35a984e4145223ef32edb208c37
5
5
  SHA512:
6
- metadata.gz: 5c4b37523f62099fa7579cb21fbac5e328536c92f4350bf86011161627e0a95e13c3452fae5cdb01ccfb27aec477b6e47384daaf445483f45c8091be3ec509d9
7
- data.tar.gz: c6e446fa97e8908eb0ac9a2443b0d94bcaa4c293818adea39b6f48e377b7aa98661a43383363ff507686070ba969d84c862d8ae1654d01ba953312c243a1bd4a
6
+ metadata.gz: b81cc25cbc94fa4f3d82bfc121ff5fb5e16900491a779a7de001ff2478270f5118a83c4dd9fc7996f17bd900825db3aa736d58be6b397e26fec86802bd30b998
7
+ data.tar.gz: 5f4a750b93964818d6b1310d6fa634ff9a094a58caa1a50961a7e6a66252a3a6cc7ce872d89a22bf5e8922f2a0238f4baf2dc178c43e4b67014d2c2b2fe9fbfd
@@ -5,6 +5,7 @@ module Awsclient
5
5
 
6
6
  class Connection
7
7
 
8
+ attr_accessor :client_options
8
9
  attr_accessor :credentials
9
10
  attr_accessor :region
10
11
 
@@ -24,6 +25,10 @@ module Awsclient
24
25
  attr_accessor svc
25
26
  end
26
27
 
28
+ def initialize(client_options = {})
29
+ self.client_options = client_options
30
+ end
31
+
27
32
  def credentials
28
33
  unless @credentials
29
34
  self.credentials = load_credentials
@@ -84,445 +89,445 @@ module Awsclient
84
89
  iam.get_user.user.arn.split(':')[4]
85
90
  end
86
91
 
87
- def acm(options = {})
92
+ def acm
88
93
  @acm ||= ::Aws::ACM::Client.new(
89
94
  credentials: credentials,
90
95
  region: region
91
96
  )
92
97
  end
93
98
 
94
- def apigateway(options = {})
99
+ def apigateway
95
100
  @apigateway ||= ::Aws::APIGateway::Client.new({
96
101
  credentials: credentials,
97
102
  region: region
98
- }.merge(options))
103
+ }.merge(client_options))
99
104
  end
100
105
 
101
- def autoscaling(options = {})
106
+ def autoscaling
102
107
  @autoscaling ||= ::Aws::AutoScaling::Client.new({
103
108
  credentials: credentials,
104
109
  region: region
105
- }.merge(options))
110
+ }.merge(client_options))
106
111
  end
107
112
 
108
- def cloudformation(options = {})
113
+ def cloudformation
109
114
  @cloudformation ||= ::Aws::CloudFormation::Client.new({
110
115
  credentials: credentials,
111
116
  region: region
112
- }.merge(options))
117
+ }.merge(client_options))
113
118
  end
114
119
 
115
- def cloudfront(options = {})
120
+ def cloudfront
116
121
  @cloudformation ||= ::Aws::CloudFront::Client.new({
117
122
  credentials: credentials,
118
123
  region: region
119
- }.merge(options))
124
+ }.merge(client_options))
120
125
  end
121
126
 
122
- def cloudhsm(options = {})
127
+ def cloudhsm
123
128
  @cloudformation ||= ::Aws::CloudHSM::Client.new({
124
129
  credentials: credentials,
125
130
  region: region
126
- }.merge(options))
131
+ }.merge(client_options))
127
132
  end
128
133
 
129
- def cloudsearch(options = {})
134
+ def cloudsearch
130
135
  @cloudformation ||= ::Aws::CloudSearch::Client.new({
131
136
  credentials: credentials,
132
137
  region: region
133
- }.merge(options))
138
+ }.merge(client_options))
134
139
  end
135
140
 
136
- def cloudtrail(options = {})
141
+ def cloudtrail
137
142
  @cloudtrail ||= ::Aws::CloudTrail::Client.new({
138
143
  credentials: credentials,
139
144
  region: region
140
- }.merge(options))
145
+ }.merge(client_options))
141
146
  end
142
147
 
143
- def cloudwatch(options = {})
148
+ def cloudwatch
144
149
  @cloudwatch ||= ::Aws::CloudWatch::Client.new({
145
150
  credentials: credentials,
146
151
  region: region
147
- }.merge(options))
152
+ }.merge(client_options))
148
153
  end
149
154
 
150
- def cloudwatchevents(options = {})
155
+ def cloudwatchevents
151
156
  @cloudwatchevents ||= ::Aws::CloudWatchEvents::Client.new({
152
157
  credentials: credentials,
153
158
  region: region
154
- }.merge(options))
159
+ }.merge(client_options))
155
160
  end
156
161
 
157
- def cloudwatchlogs(options = {})
162
+ def cloudwatchlogs
158
163
  @cloudwatchlogs ||= ::Aws::CloudWatchLogs::Client.new({
159
164
  credentials: credentials,
160
165
  region: region
161
- }.merge(options))
166
+ }.merge(client_options))
162
167
  end
163
168
 
164
- def codecommit(options = {})
169
+ def codecommit
165
170
  @codecommit ||= ::Aws::CodeCommit::Client.new({
166
171
  credentials: credentials,
167
172
  region: region
168
- }.merge(options))
173
+ }.merge(client_options))
169
174
  end
170
175
 
171
- def codedeploy(options = {})
176
+ def codedeploy
172
177
  @codedeploy ||= ::Aws::CodeDeploy::Client.new({
173
178
  credentials: credentials,
174
179
  region: region
175
- }.merge(options))
180
+ }.merge(client_options))
176
181
  end
177
182
 
178
- def codepipeline(options = {})
183
+ def codepipeline
179
184
  @codepipeline ||= ::Aws::CodePipeline::Client.new({
180
185
  credentials: credentials,
181
186
  region: region
182
- }.merge(options))
187
+ }.merge(client_options))
183
188
  end
184
189
 
185
- def cognitoidentity(options = {})
190
+ def cognitoidentity
186
191
  @cognitoidentity ||= ::Aws::CognitoIdentity::Client.new({
187
192
  credentials: credentials,
188
193
  region: region
189
- }.merge(options))
194
+ }.merge(client_options))
190
195
  end
191
196
 
192
- def cognitosync(options = {})
197
+ def cognitosync
193
198
  @cognitosync ||= ::Aws::CognitoSync::Client.new({
194
199
  credentials: credentials,
195
200
  region: region
196
- }.merge(options))
201
+ }.merge(client_options))
197
202
  end
198
203
 
199
- def configservice(options = {})
204
+ def configservice
200
205
  @codedeploy ||= ::Aws::ConfigService::Client.new({
201
206
  credentials: credentials,
202
207
  region: region
203
- }.merge(options))
208
+ }.merge(client_options))
204
209
  end
205
210
 
206
- def datapipeline(options = {})
211
+ def datapipeline
207
212
  @datapipeline ||= ::Aws::DataPipeline::Client.new({
208
213
  credentials: credentials,
209
214
  region: region
210
- }.merge(options))
215
+ }.merge(client_options))
211
216
  end
212
217
 
213
- def databasemigrationservice(options = {})
218
+ def databasemigrationservice
214
219
  @databasemigrationservice ||= ::Aws::DatabaseMigrationService::Client.new({
215
220
  credentials: credentials,
216
221
  region: region
217
- }.merge(options))
222
+ }.merge(client_options))
218
223
  end
219
224
 
220
- def devicefarm(options = {})
225
+ def devicefarm
221
226
  @devicefarm ||= ::Aws::DeviceFarm::Client.new({
222
227
  credentials: credentials,
223
228
  region: region
224
- }.merge(options))
229
+ }.merge(client_options))
225
230
  end
226
231
 
227
- def directconnect(options = {})
232
+ def directconnect
228
233
  @directconnect ||= ::Aws::DirectConnect::Client.new({
229
234
  credentials: credentials,
230
235
  region: region
231
- }.merge(options))
236
+ }.merge(client_options))
232
237
  end
233
238
 
234
- def directoryservice(options = {})
239
+ def directoryservice
235
240
  @directoryservice ||= ::Aws::DirectoryService::Client.new({
236
241
  credentials: credentials,
237
242
  region: region
238
- }.merge(options))
243
+ }.merge(client_options))
239
244
  end
240
245
 
241
- def dynamodb(options = {})
246
+ def dynamodb
242
247
  @dynamodb ||= ::Aws::DynamoDB::Client.new({
243
248
  credentials: credentials,
244
249
  region: region
245
- }.merge(options))
250
+ }.merge(client_options))
246
251
  end
247
252
 
248
- def dynamodbstreams(options = {})
253
+ def dynamodbstreams
249
254
  @dynamodbstreams ||= ::Aws::DynamoDBStreams::Client.new({
250
255
  credentials: credentials,
251
256
  region: region
252
- }.merge(options))
257
+ }.merge(client_options))
253
258
  end
254
259
 
255
- def ec2(options = {})
260
+ def ec2
256
261
  @ec2 ||= ::Aws::EC2::Client.new({
257
262
  credentials: credentials,
258
263
  region: region
259
- }.merge(options))
264
+ }.merge(client_options))
260
265
  end
261
266
 
262
- def ecr(options = {})
267
+ def ecr
263
268
  @ecr ||= ::Aws::ECR::Client.new({
264
269
  credentials: credentials,
265
270
  region: region
266
- }.merge(options))
271
+ }.merge(client_options))
267
272
  end
268
273
 
269
- def ecs(options = {})
274
+ def ecs
270
275
  @ecs ||= ::Aws::ECS::Client.new({
271
276
  credentials: credentials,
272
277
  region: region
273
- }.merge(options))
278
+ }.merge(client_options))
274
279
  end
275
280
 
276
- def efs(options = {})
281
+ def efs
277
282
  @efs ||= ::Aws::EFS::Client.new({
278
283
  credentials: credentials,
279
284
  region: region
280
- }.merge(options))
285
+ }.merge(client_options))
281
286
  end
282
287
 
283
- def emr(options = {})
288
+ def emr
284
289
  @emr ||= ::Aws::EMR::Client.new({
285
290
  credentials: credentials,
286
291
  region: region
287
- }.merge(options))
292
+ }.merge(client_options))
288
293
  end
289
294
 
290
- def elasticbeanstalk(options = {})
295
+ def elasticbeanstalk
291
296
  @elasticbeanstalk ||= ::Aws::ElasticBeanstalk::Client.new({
292
297
  credentials: credentials,
293
298
  region: region
294
- }.merge(options))
299
+ }.merge(client_options))
295
300
  end
296
301
 
297
- def elasticloadbalancing(options = {})
302
+ def elasticloadbalancing
298
303
  @elasticloadbalancing ||= ::Aws::ElasticLoadBalancing::Client.new({
299
304
  credentials: credentials,
300
305
  region: region
301
- }.merge(options))
306
+ }.merge(client_options))
302
307
  end
303
308
 
304
- def elastictranscoder(options = {})
309
+ def elastictranscoder
305
310
  @elastictranscoder ||= ::Aws::ElasticTranscoder::Client.new({
306
311
  credentials: credentials,
307
312
  region: region
308
- }.merge(options))
313
+ }.merge(client_options))
309
314
  end
310
315
 
311
- def elasticsearchservice(options = {})
316
+ def elasticsearchservice
312
317
  @elasticsearchservice ||= ::Aws::ElasticsearchService::Client.new({
313
318
  credentials: credentials,
314
319
  region: region
315
- }.merge(options))
320
+ }.merge(client_options))
316
321
  end
317
322
 
318
- def firehose(options = {})
323
+ def firehose
319
324
  @firehose ||= ::Aws::Firehose::Client.new({
320
325
  credentials: credentials,
321
326
  region: region
322
- }.merge(options))
327
+ }.merge(client_options))
323
328
  end
324
329
 
325
- def gamelift(options = {})
330
+ def gamelift
326
331
  @gamelift ||= ::Aws::GameLift::Client.new({
327
332
  credentials: credentials,
328
333
  region: region
329
- }.merge(options))
334
+ }.merge(client_options))
330
335
  end
331
336
 
332
- def glacier(options = {})
337
+ def glacier
333
338
  @glacier ||= ::Aws::Glacier::Client.new({
334
339
  credentials: credentials,
335
340
  region: region
336
- }.merge(options))
341
+ }.merge(client_options))
337
342
  end
338
343
 
339
- def iam(options = {})
344
+ def iam
340
345
  @iam ||= ::Aws::IAM::Client.new({
341
346
  credentials: credentials,
342
347
  region: region
343
- }.merge(options))
348
+ }.merge(client_options))
344
349
  end
345
350
 
346
- def importexport(options = {})
351
+ def importexport
347
352
  @importexport ||= ::Aws::ImportExport::Client.new({
348
353
  credentials: credentials,
349
354
  region: region
350
- }.merge(options))
355
+ }.merge(client_options))
351
356
  end
352
357
 
353
- def inspector(options = {})
358
+ def inspector
354
359
  @importexport ||= ::Aws::Inspector::Client.new({
355
360
  credentials: credentials,
356
361
  region: region
357
- }.merge(options))
362
+ }.merge(client_options))
358
363
  end
359
364
 
360
- def iot(options = {})
365
+ def iot
361
366
  @iot ||= ::Aws::IoT::Client.new({
362
367
  credentials: credentials,
363
368
  region: region
364
- }.merge(options))
369
+ }.merge(client_options))
365
370
  end
366
371
 
367
- def iotdataplane(options = {})
372
+ def iotdataplane
368
373
  @iotdataplane ||= ::Aws::IoTDataPlane::Client.new({
369
374
  credentials: credentials,
370
375
  region: region
371
- }.merge(options))
376
+ }.merge(client_options))
372
377
  end
373
378
 
374
- def kms(options = {})
379
+ def kms
375
380
  @kms ||= ::Aws::KMS::Client.new({
376
381
  credentials: credentials,
377
382
  region: region
378
- }.merge(options))
383
+ }.merge(client_options))
379
384
  end
380
385
 
381
- def kinesis(options = {})
386
+ def kinesis
382
387
  @kinesis ||= ::Aws::Kinesis::Client.new({
383
388
  credentials: credentials,
384
389
  region: region
385
- }.merge(options))
390
+ }.merge(client_options))
386
391
  end
387
392
 
388
- def lambda(options = {})
393
+ def lambda
389
394
  @lambda ||= ::Aws::Lambda::Client.new({
390
395
  credentials: credentials,
391
396
  region: region
392
- }.merge(options))
397
+ }.merge(client_options))
393
398
  end
394
399
 
395
- def lambdapreview(options = {})
400
+ def lambdapreview
396
401
  @lambdapreview ||= ::Aws::LambdaPreview::Client.new({
397
402
  credentials: credentials,
398
403
  region: region
399
- }.merge(options))
404
+ }.merge(client_options))
400
405
  end
401
406
 
402
- def machinelearning(options = {})
407
+ def machinelearning
403
408
  @machinelearning ||= ::Aws::MachineLearning::Client.new({
404
409
  credentials: credentials,
405
410
  region: region
406
- }.merge(options))
411
+ }.merge(client_options))
407
412
  end
408
413
 
409
- def marketplacecommerceanalytics(options = {})
414
+ def marketplacecommerceanalytics
410
415
  @marketplacecommerceanalytics ||= ::Aws::MarketplaceCommerceAnalytics::Client.new({
411
416
  credentials: credentials,
412
417
  region: region
413
- }.merge(options))
418
+ }.merge(client_options))
414
419
  end
415
420
 
416
- def rds(options = {})
421
+ def rds
417
422
  @rds ||= ::Aws::RDS::Client.new({
418
423
  credentials: credentials,
419
424
  region: region
420
- }.merge(options))
425
+ }.merge(client_options))
421
426
  end
422
427
 
423
- def route53(options = {})
428
+ def route53
424
429
  @route53 ||= ::Aws::Route53::Client.new({
425
430
  credentials: credentials,
426
431
  region: region
427
- }.merge(options))
432
+ }.merge(client_options))
428
433
  end
429
434
 
430
- def route53domains(options = {})
435
+ def route53domains
431
436
  @route53domains ||= ::Aws::Route53Domains::Client.new({
432
437
  credentials: credentials,
433
438
  region: region
434
- }.merge(options))
439
+ }.merge(client_options))
435
440
  end
436
441
 
437
- def s3(options = {})
442
+ def s3
438
443
  @s3 ||= ::Aws::S3::Client.new({
439
444
  credentials: credentials,
440
445
  region: region
441
- }.merge(options))
446
+ }.merge(client_options))
442
447
  end
443
448
 
444
449
  def s3_bucket(name, options = {})
445
450
  @bucket ||= ::Aws::S3::Bucket.new(name, {
446
451
  credentials: credentials,
447
452
  region: region
448
- }.merge(options))
453
+ }.merge(client_options))
449
454
  end
450
455
 
451
- def ses(options = {})
456
+ def ses
452
457
  @ses ||= ::Aws::SES::Client.new({
453
458
  credentials: credentials,
454
459
  region: region
455
- }.merge(options))
460
+ }.merge(client_options))
456
461
  end
457
462
 
458
- def sns(options = {})
463
+ def sns
459
464
  @sns ||= ::Aws::SNS::Client.new({
460
465
  credentials: credentials,
461
466
  region: region
462
- }.merge(options))
467
+ }.merge(client_options))
463
468
  end
464
469
 
465
- def sqs(options = {})
470
+ def sqs
466
471
  @sqs ||= ::Aws::SQS::Client.new({
467
472
  credentials: credentials,
468
473
  region: region
469
- }.merge(options))
474
+ }.merge(client_options))
470
475
  end
471
476
 
472
- def ssm(options = {})
477
+ def ssm
473
478
  @ssm ||= ::Aws::SSM::Client.new({
474
479
  credentials: credentials,
475
480
  region: region
476
- }.merge(options))
481
+ }.merge(client_options))
477
482
  end
478
483
 
479
- def sts(options = {})
484
+ def sts
480
485
  @sts ||= ::Aws::STS::Client.new({
481
486
  credentials: credentials,
482
487
  region: region
483
- }.merge(options))
488
+ }.merge(client_options))
484
489
  end
485
490
 
486
- def swf(options = {})
491
+ def swf
487
492
  @swf ||= ::Aws::SWF::Client.new({
488
493
  credentials: credentials,
489
494
  region: region
490
- }.merge(options))
495
+ }.merge(client_options))
491
496
  end
492
497
 
493
- def simpledb(options = {})
498
+ def simpledb
494
499
  @simpledb ||= ::Aws::SimpleDB::Client.new({
495
500
  credentials: credentials,
496
501
  region: region
497
- }.merge(options))
502
+ }.merge(client_options))
498
503
  end
499
504
 
500
- def storagegateway(options = {})
505
+ def storagegateway
501
506
  @storagegateway ||= ::Aws::StorageGateway::Client.new({
502
507
  credentials: credentials,
503
508
  region: region
504
- }.merge(options))
509
+ }.merge(client_options))
505
510
  end
506
511
 
507
- def support(options = {})
512
+ def support
508
513
  @support ||= ::Aws::Support::Client.new({
509
514
  credentials: credentials,
510
515
  region: region
511
- }.merge(options))
516
+ }.merge(client_options))
512
517
  end
513
518
 
514
- def waf(options = {})
519
+ def waf
515
520
  @waf ||= ::Aws::WAF::Client.new({
516
521
  credentials: credentials,
517
522
  region: region
518
- }.merge(options))
523
+ }.merge(client_options))
519
524
  end
520
525
 
521
- def workspaces(options = {})
526
+ def workspaces
522
527
  @workspaces ||= ::Aws::WorkSpaces::Client.new({
523
528
  credentials: credentials,
524
529
  region: region
525
- }.merge(options))
530
+ }.merge(client_options))
526
531
  end
527
532
 
528
533
  private
@@ -1,3 +1,3 @@
1
1
  module Awsclient
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: awsclient
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeremy Hahn
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-03-18 00:00:00.000000000 Z
11
+ date: 2016-04-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -107,7 +107,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
107
107
  version: '0'
108
108
  requirements: []
109
109
  rubyforge_project:
110
- rubygems_version: 2.4.8
110
+ rubygems_version: 2.2.2
111
111
  signing_key:
112
112
  specification_version: 4
113
113
  summary: Provides a full featured AWS client library with dynamic credential loading.