oracle.oci.oci_database_autonomous_container_database_facts – Fetches details about one or multiple AutonomousContainerDatabase resources in Oracle Cloud Infrastructure

Note

This plugin is part of the oracle.oci collection (version 4.14.0).

You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install oracle.oci.

To use it in a playbook, specify: oracle.oci.oci_database_autonomous_container_database_facts.

New in version 2.9.0: of oracle.oci

Synopsis

  • Fetches details about one or multiple AutonomousContainerDatabase resources in Oracle Cloud Infrastructure

  • Gets a list of the Autonomous Container Databases in the specified compartment.

  • If autonomous_container_database_id is specified, the details of a single AutonomousContainerDatabase will be returned.

Requirements

The below requirements are needed on the host that executes this module.

Parameters

Parameter Choices/Defaults Comments
api_user
string
The OCID of the user, on whose behalf, OCI APIs are invoked. If not set, then the value of the OCI_USER_ID environment variable, if any, is used. This option is required if the user is not specified through a configuration file (See config_file_location). To get the user's OCID, please refer https://docs.us-phoenix-1.oraclecloud.com/Content/API/Concepts/apisigningkey.htm.
api_user_fingerprint
string
Fingerprint for the key pair being used. If not set, then the value of the OCI_USER_FINGERPRINT environment variable, if any, is used. This option is required if the key fingerprint is not specified through a configuration file (See config_file_location). To get the key pair's fingerprint value please refer https://docs.us-phoenix-1.oraclecloud.com/Content/API/Concepts/apisigningkey.htm.
api_user_key_file
string
Full path and filename of the private key (in PEM format). If not set, then the value of the OCI_USER_KEY_FILE variable, if any, is used. This option is required if the private key is not specified through a configuration file (See config_file_location). If the key is encrypted with a pass-phrase, the api_user_key_pass_phrase option must also be provided.
api_user_key_pass_phrase
string
Passphrase used by the key referenced in api_user_key_file, if it is encrypted. If not set, then the value of the OCI_USER_KEY_PASS_PHRASE variable, if any, is used. This option is required if the key passphrase is not specified through a configuration file (See config_file_location).
auth_purpose
string
    Choices:
  • service_principal
The auth purpose which can be used in conjunction with 'auth_type=instance_principal'. The default auth_purpose for instance_principal is None.
auth_type
string
    Choices:
  • api_key ←
  • instance_principal
  • instance_obo_user
  • resource_principal
The type of authentication to use for making API requests. By default auth_type="api_key" based authentication is performed and the API key (see api_user_key_file) in your config file will be used. If this 'auth_type' module option is not specified, the value of the OCI_ANSIBLE_AUTH_TYPE, if any, is used. Use auth_type="instance_principal" to use instance principal based authentication when running ansible playbooks within an OCI compute instance.
autonomous_container_database_id
string
The Autonomous Container Database OCID.
Required to get a specific autonomous_container_database.

aliases: id
autonomous_exadata_infrastructure_id
string
The Autonomous Exadata Infrastructure OCID.
autonomous_vm_cluster_id
string
The Autonomous VM Cluster OCID.
availability_domain
string
A filter to return only resources that match the given availability domain exactly.
cert_bundle
string
The full path to a CA certificate bundle to be used for SSL verification. This will override the default CA certificate bundle. If not set, then the value of the OCI_ANSIBLE_CERT_BUNDLE variable, if any, is used.
cloud_autonomous_vm_cluster_id
string
The cloud Autonomous VM Cluster OCID.
compartment_id
string
The compartment OCID.
Required to list multiple autonomous_container_databases.
config_file_location
string
Path to configuration file. If not set then the value of the OCI_CONFIG_FILE environment variable, if any, is used. Otherwise, defaults to ~/.oci/config.
config_profile_name
string
The profile to load from the config file referenced by config_file_location. If not set, then the value of the OCI_CONFIG_PROFILE environment variable, if any, is used. Otherwise, defaults to the "DEFAULT" profile in config_file_location.
display_name
string
A filter to return only resources that match the entire display name given. The match is not case sensitive.

aliases: name
infrastructure_type
string
    Choices:
  • CLOUD
  • CLOUD_AT_CUSTOMER
A filter to return only resources that match the given Infrastructure Type.
lifecycle_state
string
    Choices:
  • PROVISIONING
  • AVAILABLE
  • UPDATING
  • TERMINATING
  • TERMINATED
  • FAILED
  • BACKUP_IN_PROGRESS
  • RESTORING
  • RESTORE_FAILED
  • RESTARTING
  • MAINTENANCE_IN_PROGRESS
  • ROLE_CHANGE_IN_PROGRESS
  • UNAVAILABLE
A filter to return only resources that match the given lifecycle state exactly.
region
string
The Oracle Cloud Infrastructure region to use for all OCI API requests. If not set, then the value of the OCI_REGION variable, if any, is used. This option is required if the region is not specified through a configuration file (See config_file_location). Please refer to https://docs.us-phoenix-1.oraclecloud.com/Content/General/Concepts/regions.htm for more information on OCI regions.
service_level_agreement_type
string
A filter to return only resources that match the given service-level agreement type exactly.
sort_by
string
    Choices:
  • TIMECREATED
  • DISPLAYNAME
The field to sort by. You can provide one sort order (`sortOrder`). Default order for TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME sort order is case sensitive.
**Note:** If you do not include the availability domain filter, the resources are grouped by availability domain, then sorted.
sort_order
string
    Choices:
  • ASC
  • DESC
The sort order to use, either ascending (`ASC`) or descending (`DESC`).
tenancy
string
OCID of your tenancy. If not set, then the value of the OCI_TENANCY variable, if any, is used. This option is required if the tenancy OCID is not specified through a configuration file (See config_file_location). To get the tenancy OCID, please refer https://docs.us-phoenix-1.oraclecloud.com/Content/API/Concepts/apisigningkey.htm

Examples

- name: Get a specific autonomous_container_database
  oci_database_autonomous_container_database_facts:
    # required
    autonomous_container_database_id: "ocid1.autonomouscontainerdatabase.oc1..xxxxxxEXAMPLExxxxxx"

- name: List autonomous_container_databases
  oci_database_autonomous_container_database_facts:
    # required
    compartment_id: "ocid1.compartment.oc1..xxxxxxEXAMPLExxxxxx"

    # optional
    autonomous_exadata_infrastructure_id: "ocid1.autonomousexadatainfrastructure.oc1..xxxxxxEXAMPLExxxxxx"
    autonomous_vm_cluster_id: "ocid1.autonomousvmcluster.oc1..xxxxxxEXAMPLExxxxxx"
    infrastructure_type: CLOUD
    sort_by: TIMECREATED
    sort_order: ASC
    lifecycle_state: PROVISIONING
    availability_domain: Uocm:PHX-AD-1
    display_name: display_name_example
    service_level_agreement_type: service_level_agreement_type_example
    cloud_autonomous_vm_cluster_id: "ocid1.cloudautonomousvmcluster.oc1..xxxxxxEXAMPLExxxxxx"

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
autonomous_container_databases
complex
on success
List of AutonomousContainerDatabase resources

Sample:
[{'autonomous_exadata_infrastructure_id': 'ocid1.autonomousexadatainfrastructure.oc1..xxxxxxEXAMPLExxxxxx', 'autonomous_vm_cluster_id': 'ocid1.autonomousvmcluster.oc1..xxxxxxEXAMPLExxxxxx', 'availability_domain': 'Uocm:PHX-AD-1', 'available_cpus': 3.4, 'backup_config': {'backup_destination_details': [{'id': 'ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx', 'internet_proxy': 'internet_proxy_example', 'type': 'NFS', 'vpc_password': 'example-password', 'vpc_user': 'vpc_user_example'}], 'recovery_window_in_days': 56}, 'cloud_autonomous_vm_cluster_id': 'ocid1.cloudautonomousvmcluster.oc1..xxxxxxEXAMPLExxxxxx', 'compartment_id': 'ocid1.compartment.oc1..xxxxxxEXAMPLExxxxxx', 'compute_model': 'ECPU', 'db_unique_name': 'db_unique_name_example', 'db_version': 'db_version_example', 'defined_tags': {'Operations': {'CostCenter': 'US'}}, 'display_name': 'display_name_example', 'freeform_tags': {'Department': 'Finance'}, 'id': 'ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx', 'infrastructure_type': 'CLOUD', 'key_history_entry': [{'id': 'ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx', 'kms_key_version_id': 'ocid1.kmskeyversion.oc1..xxxxxxEXAMPLExxxxxx', 'time_activated': '2013-10-20T19:20:30+01:00', 'vault_id': 'ocid1.vault.oc1..xxxxxxEXAMPLExxxxxx'}], 'key_store_id': 'ocid1.keystore.oc1..xxxxxxEXAMPLExxxxxx', 'key_store_wallet_name': 'key_store_wallet_name_example', 'kms_key_id': 'ocid1.kmskey.oc1..xxxxxxEXAMPLExxxxxx', 'kms_key_version_id': 'ocid1.kmskeyversion.oc1..xxxxxxEXAMPLExxxxxx', 'last_maintenance_run_id': 'ocid1.lastmaintenancerun.oc1..xxxxxxEXAMPLExxxxxx', 'lifecycle_details': 'lifecycle_details_example', 'lifecycle_state': 'PROVISIONING', 'maintenance_window': {'custom_action_timeout_in_mins': 56, 'days_of_week': [{'name': 'MONDAY'}], 'hours_of_day': [], 'is_custom_action_timeout_enabled': True, 'is_monthly_patching_enabled': True, 'lead_time_in_weeks': 56, 'months': [{'name': 'JANUARY'}], 'patching_mode': 'ROLLING', 'preference': 'NO_PREFERENCE', 'weeks_of_month': []}, 'memory_per_oracle_compute_unit_in_gbs': 56, 'next_maintenance_run_id': 'ocid1.nextmaintenancerun.oc1..xxxxxxEXAMPLExxxxxx', 'patch_id': 'ocid1.patch.oc1..xxxxxxEXAMPLExxxxxx', 'patch_model': 'RELEASE_UPDATES', 'provisionable_cpus': [], 'reclaimable_cpus': 3.4, 'role': 'PRIMARY', 'service_level_agreement_type': 'STANDARD', 'standby_maintenance_buffer_in_days': 56, 'time_created': '2013-10-20T19:20:30+01:00', 'time_snapshot_standby_revert': '2013-10-20T19:20:30+01:00', 'total_cpus': 56, 'vault_id': 'ocid1.vault.oc1..xxxxxxEXAMPLExxxxxx', 'version_preference': 'NEXT_RELEASE_UPDATE'}]
 
autonomous_exadata_infrastructure_id
string
on success
**No longer used.** For Autonomous Database on dedicated Exadata infrastructure, the container database is created within a specified `cloudAutonomousVmCluster`.

Sample:
ocid1.autonomousexadatainfrastructure.oc1..xxxxxxEXAMPLExxxxxx
 
autonomous_vm_cluster_id
string
on success
The OCID of the Autonomous VM Cluster.

Sample:
ocid1.autonomousvmcluster.oc1..xxxxxxEXAMPLExxxxxx
 
availability_domain
string
on success
The availability domain of the Autonomous Container Database.

Sample:
Uocm:PHX-AD-1
 
available_cpus
float
on success
Sum of CPUs available on the Autonomous VM Cluster + Sum of reclaimable CPUs available in the Autonomous Container Database.

Sample:
3.4
 
backup_config
complex
on success

   
backup_destination_details
complex
on success
Backup destination details.

     
id
string
on success
The OCID of the backup destination.

Sample:
ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx
     
internet_proxy
string
on success
Proxy URL to connect to object store.

Sample:
internet_proxy_example
     
type
string
on success
Type of the database backup destination.

Sample:
NFS
     
vpc_password
string
on success
For a RECOVERY_APPLIANCE backup destination, the password for the VPC user that is used to access the Recovery Appliance.

Sample:
example-password
     
vpc_user
string
on success
For a RECOVERY_APPLIANCE backup destination, the Virtual Private Catalog (VPC) user that is used to access the Recovery Appliance.

Sample:
vpc_user_example
   
recovery_window_in_days
integer
on success
Number of days between the current and the earliest point of recoverability covered by automatic backups. This value applies to automatic backups. After a new automatic backup has been created, Oracle removes old automatic backups that are created before the window. When the value is updated, it is applied to all existing automatic backups.

Sample:
56
 
cloud_autonomous_vm_cluster_id
string
on success
The OCID of the cloud Autonomous Exadata VM Cluster.

Sample:
ocid1.cloudautonomousvmcluster.oc1..xxxxxxEXAMPLExxxxxx
 
compartment_id
string
on success
The OCID of the compartment.

Sample:
ocid1.compartment.oc1..xxxxxxEXAMPLExxxxxx
 
compute_model
string
on success
The compute model of the Autonomous VM Cluster.

Sample:
ECPU
 
db_unique_name
string
on success
**Deprecated.** The `DB_UNIQUE_NAME` value is set by Oracle Cloud Infrastructure. Do not specify a value for this parameter. Specifying a value for this field will cause Terraform operations to fail.

Sample:
db_unique_name_example
 
db_version
string
on success
Oracle Database version of the Autonomous Container Database.

Sample:
db_version_example
 
defined_tags
dictionary
on success
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.

Sample:
{'Operations': {'CostCenter': 'US'}}
 
display_name
string
on success
The user-provided name for the Autonomous Container Database.

Sample:
display_name_example
 
freeform_tags
dictionary
on success
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags.
Example: `{"Department": "Finance"}`

Sample:
{'Department': 'Finance'}
 
id
string
on success
The OCID of the Autonomous Container Database.

Sample:
ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx
 
infrastructure_type
string
on success
The infrastructure type this resource belongs to.

Sample:
CLOUD
 
key_history_entry
complex
on success
Key History Entry.

   
id
string
on success
The id of the Autonomous Database Vault service key management history entry.

Sample:
ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx
   
kms_key_version_id
string
on success
The OCID of the key container version that is used in database transparent data encryption (TDE) operations KMS Key can have multiple key versions. If none is specified, the current key version (latest) of the Key Id is used for the operation.

Sample:
ocid1.kmskeyversion.oc1..xxxxxxEXAMPLExxxxxx
   
time_activated
string
on success
The date and time the kms key activated.

Sample:
2013-10-20T19:20:30+01:00
   
vault_id
string
on success
The OCID of the Oracle Cloud Infrastructure vault.

Sample:
ocid1.vault.oc1..xxxxxxEXAMPLExxxxxx
 
key_store_id
string
on success
The OCID of the key store.

Sample:
ocid1.keystore.oc1..xxxxxxEXAMPLExxxxxx
 
key_store_wallet_name
string
on success
The wallet name for Oracle Key Vault.

Sample:
key_store_wallet_name_example
 
kms_key_id
string
on success
The OCID of the key container that is used as the master encryption key in database transparent data encryption (TDE) operations.

Sample:
ocid1.kmskey.oc1..xxxxxxEXAMPLExxxxxx
 
kms_key_version_id
string
on success
The OCID of the key container version that is used in database transparent data encryption (TDE) operations KMS Key can have multiple key versions. If none is specified, the current key version (latest) of the Key Id is used for the operation.

Sample:
ocid1.kmskeyversion.oc1..xxxxxxEXAMPLExxxxxx
 
last_maintenance_run_id
string
on success
The OCID of the last maintenance run.

Sample:
ocid1.lastmaintenancerun.oc1..xxxxxxEXAMPLExxxxxx
 
lifecycle_details
string
on success
Additional information about the current lifecycle state.

Sample:
lifecycle_details_example
 
lifecycle_state
string
on success
The current state of the Autonomous Container Database.

Sample:
PROVISIONING
 
maintenance_window
complex
on success

   
custom_action_timeout_in_mins
integer
on success
Determines the amount of time the system will wait before the start of each database server patching operation. Custom action timeout is in minutes and valid value is between 15 to 120 (inclusive).

Sample:
56
   
days_of_week
complex
on success
Days during the week when maintenance should be performed.

     
name
string
on success
Name of the day of the week.

Sample:
MONDAY
   
hours_of_day
list / elements=string
on success
The window of hours during the day when maintenance should be performed. The window is a 4 hour slot. Valid values are - 0 - represents time slot 0:00 - 3:59 UTC - 4 - represents time slot 4:00 - 7:59 UTC - 8 - represents time slot 8:00 - 11:59 UTC - 12 - represents time slot 12:00 - 15:59 UTC - 16 - represents time slot 16:00 - 19:59 UTC - 20 - represents time slot 20:00 - 23:59 UTC

   
is_custom_action_timeout_enabled
boolean
on success
If true, enables the configuration of a custom action timeout (waiting period) between database server patching operations.

Sample:
True
   
is_monthly_patching_enabled
boolean
on success
If true, enables the monthly patching option.

Sample:
True
   
lead_time_in_weeks
integer
on success
Lead time window allows user to set a lead time to prepare for a down time. The lead time is in weeks and valid value is between 1 to 4.

Sample:
56
   
months
complex
on success
Months during the year when maintenance should be performed.

     
name
string
on success
Name of the month of the year.

Sample:
JANUARY
   
patching_mode
string
on success
Cloud Exadata infrastructure node patching method, either "ROLLING" or "NONROLLING". Default value is ROLLING.
*IMPORTANT*: Non-rolling infrastructure patching involves system down time. See Oracle-Managed Infrastructure Maintenance Updates for more information.

Sample:
ROLLING
   
preference
string
on success
The maintenance window scheduling preference.

Sample:
NO_PREFERENCE
   
weeks_of_month
list / elements=string
on success
Weeks during the month when maintenance should be performed. Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a duration of 7 days. Weeks start and end based on calendar dates, not days of the week. For example, to allow maintenance during the 2nd week of the month (from the 8th day to the 14th day of the month), use the value 2. Maintenance cannot be scheduled for the fifth week of months that contain more than 28 days. Note that this parameter works in conjunction with the daysOfWeek and hoursOfDay parameters to allow you to specify specific days of the week and hours that maintenance will be performed.

 
memory_per_oracle_compute_unit_in_gbs
integer
on success
The amount of memory (in GBs) enabled per each CPU in the Autonomous VM Cluster.

Sample:
56
 
next_maintenance_run_id
string
on success
The OCID of the next maintenance run.

Sample:
ocid1.nextmaintenancerun.oc1..xxxxxxEXAMPLExxxxxx
 
patch_id
string
on success
The OCID of the last patch applied on the system.

Sample:
ocid1.patch.oc1..xxxxxxEXAMPLExxxxxx
 
patch_model
string
on success
Database patch model preference.

Sample:
RELEASE_UPDATES
 
provisionable_cpus
list / elements=string
on success
An array of CPU values that can be used to successfully provision a single Autonomous Database.

 
reclaimable_cpus
float
on success
CPUs that continue to be included in the count of CPUs available to the Autonomous Container Database even after one of its Autonomous Database is terminated or scaled down. You can release them to the available CPUs at its parent Autonomous VM Cluster level by restarting the Autonomous Container Database.

Sample:
3.4
 
role
string
on success
The Data Guard role of the Autonomous Container Database or Autonomous Database, if Autonomous Data Guard is enabled.

Sample:
PRIMARY
 
service_level_agreement_type
string
on success
The service level agreement type of the container database. The default is STANDARD.

Sample:
STANDARD
 
standby_maintenance_buffer_in_days
integer
on success
The scheduling detail for the quarterly maintenance window of the standby Autonomous Container Database. This value represents the number of days before scheduled maintenance of the primary database.

Sample:
56
 
time_created
string
on success
The date and time the Autonomous Container Database was created.

Sample:
2013-10-20T19:20:30+01:00
 
time_snapshot_standby_revert
string
on success
The date and time the Autonomous Container Database will be reverted to Standby from Snapshot Standby.

Sample:
2013-10-20T19:20:30+01:00
 
total_cpus
integer
on success
The number of CPUs allocated to the Autonomous VM cluster.

Sample:
56
 
vault_id
string
on success
The OCID of the Oracle Cloud Infrastructure vault.

Sample:
ocid1.vault.oc1..xxxxxxEXAMPLExxxxxx
 
version_preference
string
on success
The next maintenance version preference.

Sample:
NEXT_RELEASE_UPDATE


Authors

  • Oracle (@oracle)