Only authenticated users can run the Oracle Compute Cloud Service CLI commands.
Before running the CLI commands described in this section, make sure that you've installed the CLI client and set up the required environment variables as described in Preparing to Use the Oracle Compute Cloud Service CLI.
OPC_COOKIE environment variable. This request returns an authentication token in a cookie. The token expires after 30 minutes. As the CLI tool handles authentication by managing the cookies file, you don’t need to run this command. Run this command only to explicitly set the
OPC_COOKIE environment variable, such as when you want to avoid contention between a short-lived script and cookies file and creating alternative cookies files is undesirable.
oracle-compute auth username password
Parameters and Options
For general options, see CLI Command Options.
The following parameters and options are specific to this command.
|Parameter||Required / Optional||Description|
Two-part name of the user in the format,
The password for the user. Full path and name of the file containing the password for the Oracle Compute Cloud Service user. The password file must be readable only by the owner of the file.
The account creation email from Oracle would contain the identity domain name, user name, and password, as shown in the following example:
For example, if your identity domain is
acme and the username in your account-creation email is
firstname.lastname@example.org, then the following would be the two-part user name that you must use:
oracle-compute auth /Computeemail@example.com - Password:
Some lines have been truncated with ellipses (
...) for readability. When you run the command in your environment, you'll see the full output.
Extends the expiry of the authentication token by 30 minutes from the time you run the command. Authentication tokens expire in 30 minutes. This command extends the expiry of the current authentication token, but not beyond the session expiry time, which is 3 hours.
Parameter and Options
For general command options, see CLI Command Options.