1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Database
  5. getDbVersions
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

oci.Database.getDbVersions

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

    This data source provides the list of Db Versions in Oracle Cloud Infrastructure Database service.

    Gets a list of supported Oracle Database versions.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testDbVersions = oci.Database.getDbVersions({
        compartmentId: compartmentId,
        dbSystemId: testDbSystem.id,
        dbSystemShape: dbVersionDbSystemShape,
        isDatabaseSoftwareImageSupported: dbVersionIsDatabaseSoftwareImageSupported,
        isUpgradeSupported: dbVersionIsUpgradeSupported,
        storageManagement: dbVersionStorageManagement,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_db_versions = oci.Database.get_db_versions(compartment_id=compartment_id,
        db_system_id=test_db_system["id"],
        db_system_shape=db_version_db_system_shape,
        is_database_software_image_supported=db_version_is_database_software_image_supported,
        is_upgrade_supported=db_version_is_upgrade_supported,
        storage_management=db_version_storage_management)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Database"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Database.GetDbVersions(ctx, &database.GetDbVersionsArgs{
    			CompartmentId:                    compartmentId,
    			DbSystemId:                       pulumi.StringRef(testDbSystem.Id),
    			DbSystemShape:                    pulumi.StringRef(dbVersionDbSystemShape),
    			IsDatabaseSoftwareImageSupported: pulumi.BoolRef(dbVersionIsDatabaseSoftwareImageSupported),
    			IsUpgradeSupported:               pulumi.BoolRef(dbVersionIsUpgradeSupported),
    			StorageManagement:                pulumi.StringRef(dbVersionStorageManagement),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testDbVersions = Oci.Database.GetDbVersions.Invoke(new()
        {
            CompartmentId = compartmentId,
            DbSystemId = testDbSystem.Id,
            DbSystemShape = dbVersionDbSystemShape,
            IsDatabaseSoftwareImageSupported = dbVersionIsDatabaseSoftwareImageSupported,
            IsUpgradeSupported = dbVersionIsUpgradeSupported,
            StorageManagement = dbVersionStorageManagement,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Database.DatabaseFunctions;
    import com.pulumi.oci.Database.inputs.GetDbVersionsArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var testDbVersions = DatabaseFunctions.getDbVersions(GetDbVersionsArgs.builder()
                .compartmentId(compartmentId)
                .dbSystemId(testDbSystem.id())
                .dbSystemShape(dbVersionDbSystemShape)
                .isDatabaseSoftwareImageSupported(dbVersionIsDatabaseSoftwareImageSupported)
                .isUpgradeSupported(dbVersionIsUpgradeSupported)
                .storageManagement(dbVersionStorageManagement)
                .build());
    
        }
    }
    
    variables:
      testDbVersions:
        fn::invoke:
          Function: oci:Database:getDbVersions
          Arguments:
            compartmentId: ${compartmentId}
            dbSystemId: ${testDbSystem.id}
            dbSystemShape: ${dbVersionDbSystemShape}
            isDatabaseSoftwareImageSupported: ${dbVersionIsDatabaseSoftwareImageSupported}
            isUpgradeSupported: ${dbVersionIsUpgradeSupported}
            storageManagement: ${dbVersionStorageManagement}
    

    Using getDbVersions

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getDbVersions(args: GetDbVersionsArgs, opts?: InvokeOptions): Promise<GetDbVersionsResult>
    function getDbVersionsOutput(args: GetDbVersionsOutputArgs, opts?: InvokeOptions): Output<GetDbVersionsResult>
    def get_db_versions(compartment_id: Optional[str] = None,
                        db_system_id: Optional[str] = None,
                        db_system_shape: Optional[str] = None,
                        filters: Optional[Sequence[_database.GetDbVersionsFilter]] = None,
                        is_database_software_image_supported: Optional[bool] = None,
                        is_upgrade_supported: Optional[bool] = None,
                        storage_management: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetDbVersionsResult
    def get_db_versions_output(compartment_id: Optional[pulumi.Input[str]] = None,
                        db_system_id: Optional[pulumi.Input[str]] = None,
                        db_system_shape: Optional[pulumi.Input[str]] = None,
                        filters: Optional[pulumi.Input[Sequence[pulumi.Input[_database.GetDbVersionsFilterArgs]]]] = None,
                        is_database_software_image_supported: Optional[pulumi.Input[bool]] = None,
                        is_upgrade_supported: Optional[pulumi.Input[bool]] = None,
                        storage_management: Optional[pulumi.Input[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetDbVersionsResult]
    func GetDbVersions(ctx *Context, args *GetDbVersionsArgs, opts ...InvokeOption) (*GetDbVersionsResult, error)
    func GetDbVersionsOutput(ctx *Context, args *GetDbVersionsOutputArgs, opts ...InvokeOption) GetDbVersionsResultOutput

    > Note: This function is named GetDbVersions in the Go SDK.

    public static class GetDbVersions 
    {
        public static Task<GetDbVersionsResult> InvokeAsync(GetDbVersionsArgs args, InvokeOptions? opts = null)
        public static Output<GetDbVersionsResult> Invoke(GetDbVersionsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetDbVersionsResult> getDbVersions(GetDbVersionsArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:Database/getDbVersions:getDbVersions
      arguments:
        # arguments dictionary

    The following arguments are supported:

    CompartmentId string
    The compartment OCID.
    DbSystemId string
    The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
    DbSystemShape string
    If provided, filters the results to the set of database versions which are supported for the given shape.
    Filters List<GetDbVersionsFilter>
    IsDatabaseSoftwareImageSupported bool
    If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
    IsUpgradeSupported bool
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    StorageManagement string
    The DB system storage management option. Used to list database versions available for that storage manager. Valid values are ASM and LVM.

    • ASM specifies Oracle Automatic Storage Management
    • LVM specifies logical volume manager, sometimes called logical disk manager.
    CompartmentId string
    The compartment OCID.
    DbSystemId string
    The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
    DbSystemShape string
    If provided, filters the results to the set of database versions which are supported for the given shape.
    Filters []GetDbVersionsFilter
    IsDatabaseSoftwareImageSupported bool
    If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
    IsUpgradeSupported bool
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    StorageManagement string
    The DB system storage management option. Used to list database versions available for that storage manager. Valid values are ASM and LVM.

    • ASM specifies Oracle Automatic Storage Management
    • LVM specifies logical volume manager, sometimes called logical disk manager.
    compartmentId String
    The compartment OCID.
    dbSystemId String
    The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
    dbSystemShape String
    If provided, filters the results to the set of database versions which are supported for the given shape.
    filters List<GetDbVersionsFilter>
    isDatabaseSoftwareImageSupported Boolean
    If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
    isUpgradeSupported Boolean
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    storageManagement String
    The DB system storage management option. Used to list database versions available for that storage manager. Valid values are ASM and LVM.

    • ASM specifies Oracle Automatic Storage Management
    • LVM specifies logical volume manager, sometimes called logical disk manager.
    compartmentId string
    The compartment OCID.
    dbSystemId string
    The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
    dbSystemShape string
    If provided, filters the results to the set of database versions which are supported for the given shape.
    filters GetDbVersionsFilter[]
    isDatabaseSoftwareImageSupported boolean
    If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
    isUpgradeSupported boolean
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    storageManagement string
    The DB system storage management option. Used to list database versions available for that storage manager. Valid values are ASM and LVM.

    • ASM specifies Oracle Automatic Storage Management
    • LVM specifies logical volume manager, sometimes called logical disk manager.
    compartment_id str
    The compartment OCID.
    db_system_id str
    The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
    db_system_shape str
    If provided, filters the results to the set of database versions which are supported for the given shape.
    filters Sequence[database.GetDbVersionsFilter]
    is_database_software_image_supported bool
    If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
    is_upgrade_supported bool
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    storage_management str
    The DB system storage management option. Used to list database versions available for that storage manager. Valid values are ASM and LVM.

    • ASM specifies Oracle Automatic Storage Management
    • LVM specifies logical volume manager, sometimes called logical disk manager.
    compartmentId String
    The compartment OCID.
    dbSystemId String
    The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
    dbSystemShape String
    If provided, filters the results to the set of database versions which are supported for the given shape.
    filters List<Property Map>
    isDatabaseSoftwareImageSupported Boolean
    If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
    isUpgradeSupported Boolean
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    storageManagement String
    The DB system storage management option. Used to list database versions available for that storage manager. Valid values are ASM and LVM.

    • ASM specifies Oracle Automatic Storage Management
    • LVM specifies logical volume manager, sometimes called logical disk manager.

    getDbVersions Result

    The following output properties are available:

    CompartmentId string
    DbVersions List<GetDbVersionsDbVersion>
    The list of db_versions.
    Id string
    The provider-assigned unique ID for this managed resource.
    DbSystemId string
    DbSystemShape string
    Filters List<GetDbVersionsFilter>
    IsDatabaseSoftwareImageSupported bool
    IsUpgradeSupported bool
    True if this version of the Oracle Database software is supported for Upgrade.
    StorageManagement string
    CompartmentId string
    DbVersions []GetDbVersionsDbVersion
    The list of db_versions.
    Id string
    The provider-assigned unique ID for this managed resource.
    DbSystemId string
    DbSystemShape string
    Filters []GetDbVersionsFilter
    IsDatabaseSoftwareImageSupported bool
    IsUpgradeSupported bool
    True if this version of the Oracle Database software is supported for Upgrade.
    StorageManagement string
    compartmentId String
    dbVersions List<GetDbVersionsDbVersion>
    The list of db_versions.
    id String
    The provider-assigned unique ID for this managed resource.
    dbSystemId String
    dbSystemShape String
    filters List<GetDbVersionsFilter>
    isDatabaseSoftwareImageSupported Boolean
    isUpgradeSupported Boolean
    True if this version of the Oracle Database software is supported for Upgrade.
    storageManagement String
    compartmentId string
    dbVersions GetDbVersionsDbVersion[]
    The list of db_versions.
    id string
    The provider-assigned unique ID for this managed resource.
    dbSystemId string
    dbSystemShape string
    filters GetDbVersionsFilter[]
    isDatabaseSoftwareImageSupported boolean
    isUpgradeSupported boolean
    True if this version of the Oracle Database software is supported for Upgrade.
    storageManagement string
    compartment_id str
    db_versions Sequence[database.GetDbVersionsDbVersion]
    The list of db_versions.
    id str
    The provider-assigned unique ID for this managed resource.
    db_system_id str
    db_system_shape str
    filters Sequence[database.GetDbVersionsFilter]
    is_database_software_image_supported bool
    is_upgrade_supported bool
    True if this version of the Oracle Database software is supported for Upgrade.
    storage_management str
    compartmentId String
    dbVersions List<Property Map>
    The list of db_versions.
    id String
    The provider-assigned unique ID for this managed resource.
    dbSystemId String
    dbSystemShape String
    filters List<Property Map>
    isDatabaseSoftwareImageSupported Boolean
    isUpgradeSupported Boolean
    True if this version of the Oracle Database software is supported for Upgrade.
    storageManagement String

    Supporting Types

    GetDbVersionsDbVersion

    IsLatestForMajorVersion bool
    True if this version of the Oracle Database software is the latest version for a release.
    IsPreviewDbVersion bool
    True if this version of the Oracle Database software is the preview version.
    IsUpgradeSupported bool
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    SupportsPdb bool
    True if this version of the Oracle Database software supports pluggable databases.
    Version string
    A valid Oracle Database version.
    IsLatestForMajorVersion bool
    True if this version of the Oracle Database software is the latest version for a release.
    IsPreviewDbVersion bool
    True if this version of the Oracle Database software is the preview version.
    IsUpgradeSupported bool
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    SupportsPdb bool
    True if this version of the Oracle Database software supports pluggable databases.
    Version string
    A valid Oracle Database version.
    isLatestForMajorVersion Boolean
    True if this version of the Oracle Database software is the latest version for a release.
    isPreviewDbVersion Boolean
    True if this version of the Oracle Database software is the preview version.
    isUpgradeSupported Boolean
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    supportsPdb Boolean
    True if this version of the Oracle Database software supports pluggable databases.
    version String
    A valid Oracle Database version.
    isLatestForMajorVersion boolean
    True if this version of the Oracle Database software is the latest version for a release.
    isPreviewDbVersion boolean
    True if this version of the Oracle Database software is the preview version.
    isUpgradeSupported boolean
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    supportsPdb boolean
    True if this version of the Oracle Database software supports pluggable databases.
    version string
    A valid Oracle Database version.
    is_latest_for_major_version bool
    True if this version of the Oracle Database software is the latest version for a release.
    is_preview_db_version bool
    True if this version of the Oracle Database software is the preview version.
    is_upgrade_supported bool
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    supports_pdb bool
    True if this version of the Oracle Database software supports pluggable databases.
    version str
    A valid Oracle Database version.
    isLatestForMajorVersion Boolean
    True if this version of the Oracle Database software is the latest version for a release.
    isPreviewDbVersion Boolean
    True if this version of the Oracle Database software is the preview version.
    isUpgradeSupported Boolean
    If provided, filters the results to the set of database versions which are supported for Upgrade.
    supportsPdb Boolean
    True if this version of the Oracle Database software supports pluggable databases.
    version String
    A valid Oracle Database version.

    GetDbVersionsFilter

    Name string
    Values List<string>
    Regex bool
    Name string
    Values []string
    Regex bool
    name String
    values List<String>
    regex Boolean
    name string
    values string[]
    regex boolean
    name str
    values Sequence[str]
    regex bool
    name String
    values List<String>
    regex Boolean

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi