Saturday, December 9, 2017

PCF - environment-variables

why does Cloud Foundry rely on environment-variables? Can you manage environment-variables manually? If so how? Can you name two predefined environment-variables available to any application?

Environment variables are the means by which the Cloud Foundry (CF) runtime communicates with a deployed application about its environment.

To view environment variables use 'cf env APP-NAME' command. The 'cf env' command displays the following environment variables:
The VCAP_APPLICATION and VCAP_SERVICES variables provided in the container environment
The user-provided variables set using the 'cf set-env' command

For more details refer environment-variables

System-Provided:
{
 "VCAP_SERVICES": {
  "user-provided": [
   {
    "binding_name": null,
    "credentials": {},
    "instance_name": "articulate-log-drain",
    "label": "user-provided",
    "name": "articulate-log-drain",
    "syslog_drain_url": "syslog://logs6.papertrailapp.com:26996",
    "tags": [],
    "volume_mounts": []
   }
  ]
 }
}

{
 "VCAP_APPLICATION": {
  "application_id": "ff54fe7f-12c0-42f5-a849-e223b8ec9106",
  "application_name": "articulate",
  "application_uris": [
   "articulate-clupeoid-stylization.cfapps.io",
   "articulate-v2-unrendered-daisy.cfapps.io"
  ],
  "application_version": "eb76902e-7a5a-4bc1-953d-633acead8fb4",
  "cf_api": "https://api.run.pivotal.io",
  "limits": {
   "disk": 1024,
   "fds": 16384,
   "mem": 512
  },
  "name": "articulate",
  "space_id": "541b20f9-b435-4934-ab8b-5c35e52ac8ca",
  "space_name": "development",
  "uris": [
   "articulate-clupeoid-stylization.cfapps.io",
   "articulate-v2-unrendered-daisy.cfapps.io"
  ],
  "users": null,
  "version": "eb76902e-7a5a-4bc1-953d-633acead8fb4"
 }
}

User-Provided:
JAVA_OPTS: -Xss228k

No comments:

Post a Comment

உப்பு மாங்காய்

சுருக்குப்பை கிழவி. சுருக்கங்கள் சூழ் கிழவி. பார்க்கும் போதெல்லாம் கூடையுடனே குடியிருப்பாள். கூடை நிறைய குட்டி குட்டி மாங்காய்கள். வெட்டிக்க...