regression: oci ignores OCI_CLI_RC_FILE environment variable
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 669
- Forks
- 236
- Avg merge
- 1m
- Merged PRs (30d)
- 4
Description
The documentation for the OCI CLI states:
The default location and file name for the CLI-specific configuration file is
~/.oci/oci_cli_rc, but you can use theOCI_CLI_RC_FILEenvironment variable to modify where the CLI looks for a configuration file and its default values upon startup.
This is confirmed in CHANGELOG.rst for version 2.6.9
At the present time this fails as can be seen in the following example (attempting to use the FreeDesktop defined location):
❯ cat $OCI_CLI_RC_FILE
[DEFAULT]
user=ocid1.user.oc1.......
fingerprint=ba:03:ee:44:70:65:44:9c:ff:.....
key_file=/Users/bharrington/.local/share/oci/oci_api_key.pem
tenancy=ocid1.tenancy.oc1......
region=us-phoenix-1
pass_phrase="N/A"
❯ OCI_CLI_RC_FILE=/Users/bharrington/.config/oci oci os ns get
ERROR: Could not find config file at /Users/bharrington/.oci/config
Do you want to create a new config file? [Y/n]:
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the documented OCI_CLI_RC_FILE behavior with the oci os ns get command and review the configuration details in CHANGELOG.rst. Trace the CLI's config-file resolution entry point and compare it with the documented environment-variable behavior; done means the specified file is used instead of ~/.oci/config, with coverage for the regression.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, cloud
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100