Outbound Connection Args
data class OutboundConnectionArgs(val acceptConnection: Output<Boolean>? = null, val connectionAlias: Output<String>? = null, val connectionMode: Output<String>? = null, val connectionProperties: Output<OutboundConnectionConnectionPropertiesArgs>? = null, val localDomainInfo: Output<OutboundConnectionLocalDomainInfoArgs>? = null, val remoteDomainInfo: Output<OutboundConnectionRemoteDomainInfoArgs>? = null) : ConvertibleToJava<OutboundConnectionArgs>
Manages an AWS Opensearch Outbound Connection.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const current = aws.getCallerIdentity({});
const currentGetRegion = aws.getRegion({});
const foo = new aws.opensearch.OutboundConnection("foo", {
connectionAlias: "outbound_connection",
connectionMode: "DIRECT",
localDomainInfo: {
ownerId: current.then(current => current.accountId),
region: currentGetRegion.then(currentGetRegion => currentGetRegion.name),
domainName: localDomain.domainName,
},
remoteDomainInfo: {
ownerId: current.then(current => current.accountId),
region: currentGetRegion.then(currentGetRegion => currentGetRegion.name),
domainName: remoteDomain.domainName,
},
});
Content copied to clipboard
import pulumi
import pulumi_aws as aws
current = aws.get_caller_identity()
current_get_region = aws.get_region()
foo = aws.opensearch.OutboundConnection("foo",
connection_alias="outbound_connection",
connection_mode="DIRECT",
local_domain_info={
"owner_id": current.account_id,
"region": current_get_region.name,
"domain_name": local_domain["domainName"],
},
remote_domain_info={
"owner_id": current.account_id,
"region": current_get_region.name,
"domain_name": remote_domain["domainName"],
})
Content copied to clipboard
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var current = Aws.GetCallerIdentity.Invoke();
var currentGetRegion = Aws.GetRegion.Invoke();
var foo = new Aws.OpenSearch.OutboundConnection("foo", new()
{
ConnectionAlias = "outbound_connection",
ConnectionMode = "DIRECT",
LocalDomainInfo = new Aws.OpenSearch.Inputs.OutboundConnectionLocalDomainInfoArgs
{
OwnerId = current.Apply(getCallerIdentityResult => getCallerIdentityResult.AccountId),
Region = currentGetRegion.Apply(getRegionResult => getRegionResult.Name),
DomainName = localDomain.DomainName,
},
RemoteDomainInfo = new Aws.OpenSearch.Inputs.OutboundConnectionRemoteDomainInfoArgs
{
OwnerId = current.Apply(getCallerIdentityResult => getCallerIdentityResult.AccountId),
Region = currentGetRegion.Apply(getRegionResult => getRegionResult.Name),
DomainName = remoteDomain.DomainName,
},
});
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws"
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/opensearch"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
current, err := aws.GetCallerIdentity(ctx, &aws.GetCallerIdentityArgs{}, nil)
if err != nil {
return err
}
currentGetRegion, err := aws.GetRegion(ctx, &aws.GetRegionArgs{}, nil)
if err != nil {
return err
}
_, err = opensearch.NewOutboundConnection(ctx, "foo", &opensearch.OutboundConnectionArgs{
ConnectionAlias: pulumi.String("outbound_connection"),
ConnectionMode: pulumi.String("DIRECT"),
LocalDomainInfo: &opensearch.OutboundConnectionLocalDomainInfoArgs{
OwnerId: pulumi.String(current.AccountId),
Region: pulumi.String(currentGetRegion.Name),
DomainName: pulumi.Any(localDomain.DomainName),
},
RemoteDomainInfo: &opensearch.OutboundConnectionRemoteDomainInfoArgs{
OwnerId: pulumi.String(current.AccountId),
Region: pulumi.String(currentGetRegion.Name),
DomainName: pulumi.Any(remoteDomain.DomainName),
},
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.AwsFunctions;
import com.pulumi.aws.inputs.GetCallerIdentityArgs;
import com.pulumi.aws.inputs.GetRegionArgs;
import com.pulumi.aws.opensearch.OutboundConnection;
import com.pulumi.aws.opensearch.OutboundConnectionArgs;
import com.pulumi.aws.opensearch.inputs.OutboundConnectionLocalDomainInfoArgs;
import com.pulumi.aws.opensearch.inputs.OutboundConnectionRemoteDomainInfoArgs;
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 current = AwsFunctions.getCallerIdentity();
final var currentGetRegion = AwsFunctions.getRegion();
var foo = new OutboundConnection("foo", OutboundConnectionArgs.builder()
.connectionAlias("outbound_connection")
.connectionMode("DIRECT")
.localDomainInfo(OutboundConnectionLocalDomainInfoArgs.builder()
.ownerId(current.applyValue(getCallerIdentityResult -> getCallerIdentityResult.accountId()))
.region(currentGetRegion.applyValue(getRegionResult -> getRegionResult.name()))
.domainName(localDomain.domainName())
.build())
.remoteDomainInfo(OutboundConnectionRemoteDomainInfoArgs.builder()
.ownerId(current.applyValue(getCallerIdentityResult -> getCallerIdentityResult.accountId()))
.region(currentGetRegion.applyValue(getRegionResult -> getRegionResult.name()))
.domainName(remoteDomain.domainName())
.build())
.build());
}
}
Content copied to clipboard
resources:
foo:
type: aws:opensearch:OutboundConnection
properties:
connectionAlias: outbound_connection
connectionMode: DIRECT
localDomainInfo:
ownerId: ${current.accountId}
region: ${currentGetRegion.name}
domainName: ${localDomain.domainName}
remoteDomainInfo:
ownerId: ${current.accountId}
region: ${currentGetRegion.name}
domainName: ${remoteDomain.domainName}
variables:
current:
fn::invoke:
function: aws:getCallerIdentity
arguments: {}
currentGetRegion:
fn::invoke:
function: aws:getRegion
arguments: {}
Content copied to clipboard
Import
Using pulumi import
, import AWS Opensearch Outbound Connections using the Outbound Connection ID. For example:
$ pulumi import aws:opensearch/outboundConnection:OutboundConnection foo connection-id
Content copied to clipboard
Constructors
Link copied to clipboard
constructor(acceptConnection: Output<Boolean>? = null, connectionAlias: Output<String>? = null, connectionMode: Output<String>? = null, connectionProperties: Output<OutboundConnectionConnectionPropertiesArgs>? = null, localDomainInfo: Output<OutboundConnectionLocalDomainInfoArgs>? = null, remoteDomainInfo: Output<OutboundConnectionRemoteDomainInfoArgs>? = null)
Properties
Link copied to clipboard
Accepts the connection.
Link copied to clipboard
Specifies the connection alias that will be used by the customer for this connection.
Link copied to clipboard
Specifies the connection mode. Accepted values are DIRECT
or VPC_ENDPOINT
.
Link copied to clipboard
Configuration block for the outbound connection.
Link copied to clipboard
Configuration block for the local Opensearch domain.
Link copied to clipboard
Configuration block for the remote Opensearch domain.