[bulk_api] fix AppConfig entries for bulk_api credentials

Change-Id: I94a30a8555022834fc73eb5d1ddcce17b1450901
This commit is contained in:
Bob Nugmanov 2012-01-25 17:00:28 -08:00
Родитель eaba422feb
Коммит 3be88f99b6
1 изменённых файлов: 8 добавлений и 4 удалений

Просмотреть файл

@ -48,10 +48,6 @@ required = { :external_uri => 'api.vcap.me',
:keys => { :password => 'da39a3ee5e6b4b0d3255bfef95601890afd80709', :token => 'default_key'},
:pid => '/var/vcap/sys/run/cloudcontroller.pid',
:admins => [],
:bulk_api => { :auth =>
{ :user => 'bulk_api',
:password => VCAP.secure_uuid}},
:https_required => false,
:https_required_for_admins => false,
:default_account_capacity => { :memory => 2048,
@ -93,6 +89,14 @@ env_overrides.each do |cfg_key, env_key|
end
end
#generate bulk api credentials unless they've been explicitly specified (not that they should)
unless AppConfig.key? :bulk_api
AppConfig[:bulk_api] = { :auth =>
{ :user => 'bulk_api',
:password => VCAP.secure_uuid }}
end
# Check on new style app_uris and map old into new style.
unless AppConfig.key? :app_uris
AppConfig[:app_uris] = {