Viewing the account details using rhc

In this recipe, you will learn how to view your account details using rhc.

Getting ready

To complete this recipe, you will need to have rhc installed on your machine. Refer to the Installing the OpenShift rhc command-line client recipe for instructions.

How to do it…

To view the account details, run the rhc account command as follows:

$ rhc account

This is all you need to do to view the account details.

How it works…

The rhc account command shows details about the currently logged-in user. When you run the command, it makes a REST call to the OpenShift REST API using the authentication token generated during rhc setup. The REST API returns a JSON response, which rhc will render in a human-readable format:

$ rhc ...

Get OpenShift Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.