Permalink
Browse files

Custom parse marketplace gateway config

 - Avoid token check failure in vcap-services-base

Change-Id: Ie357ec8405d19a4264beb9e90ce4891032b968e9
  • Loading branch information...
1 parent 9761d5b commit 0ab7ccc789c76d40f00e4ef50bc670613acf6f64 Harshawardhan Gadgil committed Nov 30, 2012
Showing with 8 additions and 8 deletions.
  1. +8 −8 marketplace/bin/marketplace_gateway
@@ -39,17 +39,17 @@ class VCAP::Services::Marketplace::Gateway < VCAP::Services::Base::Gateway
end.parse!
begin
- @config = parse_gateway_config(config_file)
+ @config = YAML.load_file(config_file)
+ @config = VCAP.symbolize_keys(@config)
+
+ marketplace = @config[:marketplace]
+ marketplace_config = YAML.load_file(File.join(File.dirname(config_file), "#{marketplace}.yml"))
+ marketplace_config = VCAP.symbolize_keys(marketplace_config)
+ @config = @config.merge(marketplace_config)
rescue => e
- puts "Couldn't read config file: #{e}"
+ puts "Failed to read configuration: #{e}"
exit
end
-
- marketplace = @config[:marketplace]
- marketplace_config = YAML.load_file(File.join(File.dirname(config_file), "#{marketplace}.yml"))
- marketplace_config = VCAP.symbolize_keys(marketplace_config)
-
- @config = @config.merge(marketplace_config)
end
def start

0 comments on commit 0ab7ccc

Please sign in to comment.