oci.Opensearch.getOpensearchVersions
This data source provides the list of Opensearch Versions in Oracle Cloud Infrastructure Opensearch service.
Lists the supported Opensearch versions
Prerequisites
The below policies must be created in compartment before creating OpensearchCluster
{Compartment-Name} - Name of your compartment
Allow service opensearch to manage vnics in compartment {Compartment-Name}
Allow service opensearch to use subnets in compartment {Compartment-Name}
Allow service opensearch to use network-security-groups in compartment {Compartment-Name}
Allow service opensearch to manage vcns in compartment {Compartment-Name}
For latest documentation on OpenSearch use please refer to https://docs.oracle.com/en-us/iaas/Content/search-opensearch/home.htm
Required permissions: https://docs.oracle.com/en-us/iaas/Content/search-opensearch/Concepts/ocisearchpermissions.htm
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testOpensearchVersions = oci.Opensearch.getOpensearchVersions({
    compartmentId: compartmentId,
});
import pulumi
import pulumi_oci as oci
test_opensearch_versions = oci.Opensearch.get_opensearch_versions(compartment_id=compartment_id)
package main
import (
	"github.com/pulumi/pulumi-oci/sdk/v3/go/oci/opensearch"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := opensearch.GetOpensearchVersions(ctx, &opensearch.GetOpensearchVersionsArgs{
			CompartmentId: compartmentId,
		}, 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 testOpensearchVersions = Oci.Opensearch.GetOpensearchVersions.Invoke(new()
    {
        CompartmentId = compartmentId,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Opensearch.OpensearchFunctions;
import com.pulumi.oci.Opensearch.inputs.GetOpensearchVersionsArgs;
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 testOpensearchVersions = OpensearchFunctions.getOpensearchVersions(GetOpensearchVersionsArgs.builder()
            .compartmentId(compartmentId)
            .build());
    }
}
variables:
  testOpensearchVersions:
    fn::invoke:
      function: oci:Opensearch:getOpensearchVersions
      arguments:
        compartmentId: ${compartmentId}
Using getOpensearchVersions
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 getOpensearchVersions(args: GetOpensearchVersionsArgs, opts?: InvokeOptions): Promise<GetOpensearchVersionsResult>
function getOpensearchVersionsOutput(args: GetOpensearchVersionsOutputArgs, opts?: InvokeOptions): Output<GetOpensearchVersionsResult>def get_opensearch_versions(compartment_id: Optional[str] = None,
                            filters: Optional[Sequence[GetOpensearchVersionsFilter]] = None,
                            opts: Optional[InvokeOptions] = None) -> GetOpensearchVersionsResult
def get_opensearch_versions_output(compartment_id: Optional[pulumi.Input[str]] = None,
                            filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetOpensearchVersionsFilterArgs]]]] = None,
                            opts: Optional[InvokeOptions] = None) -> Output[GetOpensearchVersionsResult]func GetOpensearchVersions(ctx *Context, args *GetOpensearchVersionsArgs, opts ...InvokeOption) (*GetOpensearchVersionsResult, error)
func GetOpensearchVersionsOutput(ctx *Context, args *GetOpensearchVersionsOutputArgs, opts ...InvokeOption) GetOpensearchVersionsResultOutput> Note: This function is named GetOpensearchVersions in the Go SDK.
public static class GetOpensearchVersions 
{
    public static Task<GetOpensearchVersionsResult> InvokeAsync(GetOpensearchVersionsArgs args, InvokeOptions? opts = null)
    public static Output<GetOpensearchVersionsResult> Invoke(GetOpensearchVersionsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetOpensearchVersionsResult> getOpensearchVersions(GetOpensearchVersionsArgs args, InvokeOptions options)
public static Output<GetOpensearchVersionsResult> getOpensearchVersions(GetOpensearchVersionsArgs args, InvokeOptions options)
fn::invoke:
  function: oci:Opensearch/getOpensearchVersions:getOpensearchVersions
  arguments:
    # arguments dictionaryThe following arguments are supported:
- CompartmentId string
- The ID of the compartment in which to list resources.
- Filters
List<GetOpensearch Versions Filter> 
- CompartmentId string
- The ID of the compartment in which to list resources.
- Filters
[]GetOpensearch Versions Filter 
- compartmentId String
- The ID of the compartment in which to list resources.
- filters
List<GetVersions Filter> 
- compartmentId string
- The ID of the compartment in which to list resources.
- filters
GetOpensearch Versions Filter[] 
- compartment_id str
- The ID of the compartment in which to list resources.
- filters
Sequence[GetOpensearch Versions Filter] 
- compartmentId String
- The ID of the compartment in which to list resources.
- filters List<Property Map>
getOpensearchVersions Result
The following output properties are available:
- CompartmentId string
- Id string
- The provider-assigned unique ID for this managed resource.
- OpensearchVersions List<GetCollections Opensearch Versions Opensearch Versions Collection> 
- The list of opensearch_versions_collection.
- Filters
List<GetOpensearch Versions Filter> 
- CompartmentId string
- Id string
- The provider-assigned unique ID for this managed resource.
- OpensearchVersions []GetCollections Opensearch Versions Opensearch Versions Collection 
- The list of opensearch_versions_collection.
- Filters
[]GetOpensearch Versions Filter 
- compartmentId String
- id String
- The provider-assigned unique ID for this managed resource.
- opensearchVersions List<GetCollections Versions Versions Collection> 
- The list of opensearch_versions_collection.
- filters
List<GetVersions Filter> 
- compartmentId string
- id string
- The provider-assigned unique ID for this managed resource.
- opensearchVersions GetCollections Opensearch Versions Opensearch Versions Collection[] 
- The list of opensearch_versions_collection.
- filters
GetOpensearch Versions Filter[] 
- compartment_id str
- id str
- The provider-assigned unique ID for this managed resource.
- opensearch_versions_ Sequence[Getcollections Opensearch Versions Opensearch Versions Collection] 
- The list of opensearch_versions_collection.
- filters
Sequence[GetOpensearch Versions Filter] 
- compartmentId String
- id String
- The provider-assigned unique ID for this managed resource.
- opensearchVersions List<Property Map>Collections 
- The list of opensearch_versions_collection.
- filters List<Property Map>
Supporting Types
GetOpensearchVersionsFilter   
GetOpensearchVersionsOpensearchVersionsCollection     
- Items
List<GetOpensearch Versions Opensearch Versions Collection Item> 
- A list of OpenSearch versions.
- Items
[]GetOpensearch Versions Opensearch Versions Collection Item 
- A list of OpenSearch versions.
- items
List<GetVersions Versions Collection Item> 
- A list of OpenSearch versions.
- items
GetOpensearch Versions Opensearch Versions Collection Item[] 
- A list of OpenSearch versions.
- items
Sequence[GetOpensearch Versions Opensearch Versions Collection Item] 
- A list of OpenSearch versions.
- items List<Property Map>
- A list of OpenSearch versions.
GetOpensearchVersionsOpensearchVersionsCollectionItem      
- Version string
- The version of OpenSearch.
- Version string
- The version of OpenSearch.
- version String
- The version of OpenSearch.
- version string
- The version of OpenSearch.
- version str
- The version of OpenSearch.
- version String
- The version of OpenSearch.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the ociTerraform Provider.
