Assigning a Key to an Object Storage Bucket

Assigning a key to a new Object Storage bucket using the OCI Console, CLI, and API interfaces.

    1. Open the navigation menu and click Storage. Under Object Storage & Archive Storage, click Buckets.
    2. Under List Scope, in the Compartment list, choose the compartment where you want to create a bucket that's encrypted with a Vault service master encryption key.
    3. Click Create Bucket, and then follow the instructions in Creating an Object Storage Bucket.

  • Open a command prompt and run oci os bucket create to create a bucket that is encrypted with a Vault service master encryption key:

    oci os bucket create --name <bucket_name> --compartment-id <target_compartment_id> --kms-key-id <target_key_id>

    For example:

    
    oci os bucket create --name Bucket-1 --compartment-id ocid1.compartment.oc1..example1example25qrlpo4agcmothkbgqgmuz2zzum45ibplooqtabwk3zz --kms-key-id ocid1.key.region1.sea.exampleaaacu2.examplesmtpsuqmoy4m5cvblugmizcoeu2nfc6b3zfaux2lmqz245gezevsq --namespace-name example_namespace

    For a complete list of parameters and values for CLI commands, see KMS CLI Command Reference.

  • Run the CreateBucket and UpdateBucket operations to create and assign a vault key to an object storage bucket.

    For information about using the API and signing requests, see REST API documentation and Security Credentials. For information about SDKs, see SDKs and the CLI.