Skip to content

Add OCI plugin with API key support and CLI configurations - #653

Open
felipebz wants to merge 1 commit into
1Password:mainfrom
felipebz:oci-cli
Open

Add OCI plugin with API key support and CLI configurations#653
felipebz wants to merge 1 commit into
1Password:mainfrom
felipebz:oci-cli

Conversation

@felipebz

@felipebz felipebz commented Aug 2, 2026

Copy link
Copy Markdown

Overview

This PR introduces a new shell plugin for the Oracle Cloud Infrastructure CLI (oci).

It securely provisions the necessary authentication details in memory using OCI CLI's native environment variables (OCI_CLI_USER, OCI_CLI_TENANCY, OCI_CLI_FINGERPRINT, OCI_CLI_REGION, and OCI_CLI_KEY_CONTENT).

Additionally, this implementation includes a robust importer that handles real-world OCI configurations (addressing the architectural limitations of the previous attempt in #401). The importer:

  • Correctly parses the standard ~/.oci/config as an INI file.
  • Dynamically iterates over all configured profiles (not just the DEFAULT section).
  • Properly resolves the key_file path, safely expanding ~/ to the user's home directory.
  • Reads the local private key content to allow seamless importation of existing local configurations straight into the 1Password vault.

Type of change

  • Created a new plugin
  • Improved an existing plugin
  • Fixed a bug in an existing plugin
  • Improved contributor utilities or experience

Related Issue(s)

How To Test

  1. Compile the plugin locally: make oci/build
  2. Run an OCI command to trigger the importer (assuming you have a valid ~/.oci/config and .pem key file on your machine):
    oci iam region list
  3. Follow the prompt to import the discovered credentials into your 1Password vault.
  4. Run another authenticated command to verify the in-memory credential provisioning is working correctly:
    oci os ns get or oci iam region list

Changelog

Authenticate the Oracle Cloud Infrastructure CLI (oci) with 1Password Shell Plugins.

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

Successfully merging this pull request may close these issues.

New plugin: oci cli (Oracle Cloud Infrastructure)

1 participant