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

OCI CLI Interactive - Default value for compartment-id is not working in interactive mode. #872

Open
vamshikrishna83 opened this issue Nov 13, 2024 · 0 comments

Comments

@vamshikrishna83
Copy link

As per https://docs.oracle.com/en-us/iaas/Content/API/SDKDocs/cliconfigure.htm#Specifying_Default_Values, We can store default values for options in oci_cli_rc file which works fine when we run the commands in non-interactive mode.

But, when OCI CLI is used in interactive mode, these default values are not being honored or considered - which is resulting in error Error: Missing required parameters ['--compartment-id']

For example with api-gateway.compartment-id default value specified in configuration:

  • Command oci api-gateway deployment list --lifecycle-state ACTIVE works and returns list of ACTIVE deployments in the default compartment.
  • Command oci api-gateway deployment list works fine in interactive mode, and returns list of all deployments in default compartment.
  • Command oci api-gateway deployment list --lifecycle-state ACTIVE doesn't work in interactive mode, and returns error Error: Missing required parameters ['--compartment-id']

Expected:

  • Command oci api-gateway deployment list --lifecycle-state ACTIVE should return list of all deployments in the default compartment.
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