Reputation:
is there a way in cf to update the vcap env port
for service by code from my application, lets say I want to change the port
to 12345
e.g.
{
"VCAP_SERVICES": {
"mongodb": [
{
"credentials": {
"dbname": "ztmvvvmtrz",
"hostname": "13.15.241.29",
"password": "abzArl7AsssseKpi",
"port": "22241",
while trying the cf set-env
its update the user provided env
and wasn't able to help...
some example on java / node.js
will by great
Upvotes: 0
Views: 340
Reputation: 15041
I'm not sure exactly which information you're looking to change here, but values in environment variables like VCAP_SERVICES
, VCAP_APPLICATION
, PORT
and anything starting with CF_
like CF_INSTANCE_PORT
, CF_INSTANCE_PORTS
and/or CF_INSTANCE_IP
are all provided for you by the platform. They are effectively static. Changing them will not do anything.
Upvotes: 1