Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add an N|Solid tag for cf org, as is done for cf space #1

Closed
pmuellr opened this issue Nov 30, 2016 · 2 comments
Closed

add an N|Solid tag for cf org, as is done for cf space #1

pmuellr opened this issue Nov 30, 2016 · 2 comments

Comments

@pmuellr
Copy link
Contributor

pmuellr commented Nov 30, 2016

Would be nice to add an additional N|Solid tag (via env var NSOLID_TAGS for the org, like we already do for the space.

Here's an example of NSOLID_TAGS from a live application:

cfAppId:[uuid-here],cfAppVersion:[uuid-here],cfSpace:development

@pmuellr
Copy link
Contributor Author

pmuellr commented Nov 30, 2016

We currently get the tags we add from the env var VCAP_APPLICATION, which has the following interesting properties:

{
    "application_id": "[uuid-here]",
    "application_name": "pjm-hello-world",
    "application_version": "[uuid-here]",
    "cf_api": "https://api.run.pivotal.io",
    "instance_id": "[uuid-here]",
    "space_id": "[uuid-here]",
    "space_name": "development"
}

So ... no info on the org is directly available from VCAP_APPLICATION. Poking around other env vars, didn't see anything there either.

Curious as to why org_id and org_name aren't listed here ... should bubble this back up through the Cloud Foundry org.

The relevant org data COULD be obtained indirectly, by interacting with the cloud controller directly, or via cf, but ... that would require full login credentials to be able to get the info, which doesn't seem like a safe thing to do.

Other alternatives would be to automagically add the org name at deployment time, via deployment scripts / manifests / tooling, which would seed the NSOLID_TAGS env var with the calculated tag.

@pmuellr
Copy link
Contributor Author

pmuellr commented Jun 9, 2017

closing as there's not much we can do in the buildpack itself

@pmuellr pmuellr closed this as completed Jun 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant