Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi
oci.Psql.getDbSystemPrimaryDbInstance
Explore with Pulumi AI
This data source provides details about a specific Db System Primary Db Instance resource in Oracle Cloud Infrastructure Psql service.
Gets the primary database instance node details.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testDbSystemPrimaryDbInstance = oci.Psql.getDbSystemPrimaryDbInstance({
dbSystemId: testDbSystem.id,
});
import pulumi
import pulumi_oci as oci
test_db_system_primary_db_instance = oci.Psql.get_db_system_primary_db_instance(db_system_id=test_db_system["id"])
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Psql"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := Psql.GetDbSystemPrimaryDbInstance(ctx, &psql.GetDbSystemPrimaryDbInstanceArgs{
DbSystemId: testDbSystem.Id,
}, 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 testDbSystemPrimaryDbInstance = Oci.Psql.GetDbSystemPrimaryDbInstance.Invoke(new()
{
DbSystemId = testDbSystem.Id,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Psql.PsqlFunctions;
import com.pulumi.oci.Psql.inputs.GetDbSystemPrimaryDbInstanceArgs;
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 testDbSystemPrimaryDbInstance = PsqlFunctions.getDbSystemPrimaryDbInstance(GetDbSystemPrimaryDbInstanceArgs.builder()
.dbSystemId(testDbSystem.id())
.build());
}
}
variables:
testDbSystemPrimaryDbInstance:
fn::invoke:
Function: oci:Psql:getDbSystemPrimaryDbInstance
Arguments:
dbSystemId: ${testDbSystem.id}
Using getDbSystemPrimaryDbInstance
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 getDbSystemPrimaryDbInstance(args: GetDbSystemPrimaryDbInstanceArgs, opts?: InvokeOptions): Promise<GetDbSystemPrimaryDbInstanceResult>
function getDbSystemPrimaryDbInstanceOutput(args: GetDbSystemPrimaryDbInstanceOutputArgs, opts?: InvokeOptions): Output<GetDbSystemPrimaryDbInstanceResult>
def get_db_system_primary_db_instance(db_system_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetDbSystemPrimaryDbInstanceResult
def get_db_system_primary_db_instance_output(db_system_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDbSystemPrimaryDbInstanceResult]
func GetDbSystemPrimaryDbInstance(ctx *Context, args *GetDbSystemPrimaryDbInstanceArgs, opts ...InvokeOption) (*GetDbSystemPrimaryDbInstanceResult, error)
func GetDbSystemPrimaryDbInstanceOutput(ctx *Context, args *GetDbSystemPrimaryDbInstanceOutputArgs, opts ...InvokeOption) GetDbSystemPrimaryDbInstanceResultOutput
> Note: This function is named GetDbSystemPrimaryDbInstance
in the Go SDK.
public static class GetDbSystemPrimaryDbInstance
{
public static Task<GetDbSystemPrimaryDbInstanceResult> InvokeAsync(GetDbSystemPrimaryDbInstanceArgs args, InvokeOptions? opts = null)
public static Output<GetDbSystemPrimaryDbInstanceResult> Invoke(GetDbSystemPrimaryDbInstanceInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDbSystemPrimaryDbInstanceResult> getDbSystemPrimaryDbInstance(GetDbSystemPrimaryDbInstanceArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: oci:Psql/getDbSystemPrimaryDbInstance:getDbSystemPrimaryDbInstance
arguments:
# arguments dictionary
The following arguments are supported:
- Db
System stringId - A unique identifier for the database system.
- Db
System stringId - A unique identifier for the database system.
- db
System StringId - A unique identifier for the database system.
- db
System stringId - A unique identifier for the database system.
- db_
system_ strid - A unique identifier for the database system.
- db
System StringId - A unique identifier for the database system.
getDbSystemPrimaryDbInstance Result
The following output properties are available:
- Db
Instance stringId - A unique identifier for the primary database instance node.
- Db
System stringId - Id string
- The provider-assigned unique ID for this managed resource.
- Db
Instance stringId - A unique identifier for the primary database instance node.
- Db
System stringId - Id string
- The provider-assigned unique ID for this managed resource.
- db
Instance StringId - A unique identifier for the primary database instance node.
- db
System StringId - id String
- The provider-assigned unique ID for this managed resource.
- db
Instance stringId - A unique identifier for the primary database instance node.
- db
System stringId - id string
- The provider-assigned unique ID for this managed resource.
- db_
instance_ strid - A unique identifier for the primary database instance node.
- db_
system_ strid - id str
- The provider-assigned unique ID for this managed resource.
- db
Instance StringId - A unique identifier for the primary database instance node.
- db
System StringId - id String
- The provider-assigned unique ID for this managed resource.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.