bbc-cosmos-config 0.0.6 → 0.0.7

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: f635c48e15962d6b424741817be01b927409315f
4
- data.tar.gz: 73d133bc35db9f6e5f051f337595b8c0bcc130cc
3
+ metadata.gz: 355ed319bc64cb9079d45178d0f65d3a19e18cf4
4
+ data.tar.gz: 864acc84e87dbae6e9f38207d835aae1a50c8052
5
5
  SHA512:
6
- metadata.gz: 65e88a2bd96cc8892e6be4ba9bc3878b89a95edf8592df8852a6ac2f8de0bf02d56ae1bc12b25cdc3dd698f7e690f66f9f5ae3ceb01c9b677818224d10aef3ed
7
- data.tar.gz: 74c4391ea415065592a3c4ecce19f0b38c39dae4ade922c96e64d31aca454a6eedc56f69ed0cda1faac4c0835ef07099eb95dca041c973a1b16c53a8b7bec68e
6
+ metadata.gz: 1c8cd3a9559f92db83e2e52f481bde15390ddf7431df4003a91e3784c471f421ea095af6f19bcae86ef112aab03fb4502e0f59b7dffdfaec2aef2f8b6ac5dfdf
7
+ data.tar.gz: 6a6e2d8475c8cee7b4e9930d84ddc685c8b6583f22b187fdef599b7fab3f9d6202b9b2a07fc03866f1d8ff3cc34ec7c8d7a3d86c5f4a51cc9d0d130d4822fd02
@@ -20,7 +20,7 @@ module BBC
20
20
  end
21
21
 
22
22
  def config(config, path)
23
- BBC::Cosmos.production? ? s3_config(config[:component_resources_bucket], path, config[:configuration][:commit]) : config[:configuration]
23
+ BBC::Cosmos.production? ? s3_config(config[:component_resources_bucket], path, config[:environment], config[:configuration][:commit]) : config[:configuration]
24
24
  end
25
25
 
26
26
  private
@@ -29,8 +29,8 @@ module BBC
29
29
  tags.to_h['Renderer']
30
30
  end
31
31
 
32
- def s3_config(bucket, path, version)
33
- JSON.parse(@s3.buckets[bucket].objects["#{path}/config/#{version}/#{s3_config_location}.json"].read, :symbolize_names => true)
32
+ def s3_config(bucket, path, env, version)
33
+ JSON.parse(@s3.buckets[bucket].objects["#{path}/#{env}/config/#{version}/#{s3_config_location}.json"].read, :symbolize_names => true)
34
34
  end
35
35
 
36
36
  def instance
@@ -1,7 +1,7 @@
1
1
  module BBC
2
2
  module Cosmos
3
3
  module Config
4
- VERSION = "0.0.6"
4
+ VERSION = "0.0.7"
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bbc-cosmos-config
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Kenny