IBM Bluemix获取环境变量VCAP_SERVICES
2015-06-14 本文已影响292人
aapu
json_decode(getenv('VCAP_SERVICES'), true)['cleardb'][0]['credentials']['name']
json_decode(getenv('VCAP_SERVICES'), true)['cleardb'][0]['credentials']['username']
json_decode(getenv('VCAP_SERVICES'), true)['cleardb'][0]['credentials']['password']
json_decode(getenv('VCAP_SERVICES'), true)['cleardb'][0]['credentials']['hostname']