Re: Java: How to find out user, org, application
David Farrell
Hi,
toggle quoted message
Show quoted text
To find *Org name* you could use something like *cf curl /v2/apps/`cf app spring-music --guid`/summary | jq -r ".space_guid" | xargs -I '<guid>' cf curl '/v2/spaces/<guid>' | jq -r ".entity.organization_url" | xargs -I '<org_url>' cf curl '<org_url>' | jq -r '.entity.name <http://entity.name>' | xargs -I '<org_name>' echo Org Name : '<org_name>' * To find *Space name* you could use something like *cf curl /v2/apps/`cf app spring-music --guid`/summary | jq -r ".space_guid" | xargs -I '<guid>' cf curl '/v2/spaces/<guid>' | jq -r ".entity.name <http://entity.name>" | xargs -I '<space_name>' echo Space name : '<space_name>' * Replace *spring-music *with your app name Note. You might have to install jq [0] or else replace with something like sed, awk and grep [0] - https://stedolan.github.io/jq/ On 11 April 2017 at 11:46, CF_genn <CF_subscription(a)streber24.de> wrote:
Hi CF-DEV, --
Kind Regards, David Farrell Pivotal Global Support Services (GSS) Email: dafarrell(a)pivotal.io Office #: +353 21 4238482 Office Hours: Mon-Fri 8:30 AM to 5PM <GMT+1> Out of Office Hours Contact +1 877-477-2269 Pivotal GSS Contact & Escalations: https://discuss.zendesk.com/hc/en-us/articles/203809556 pivotal.io |
|