aws.directconnect.ConnectionAssociation
Associates a Direct Connect Connection with a LAG.
Example Usage
using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var exampleConnection = new Aws.DirectConnect.Connection("exampleConnection", new()
{
Bandwidth = "1Gbps",
Location = "EqSe2-EQ",
});
var exampleLinkAggregationGroup = new Aws.DirectConnect.LinkAggregationGroup("exampleLinkAggregationGroup", new()
{
ConnectionsBandwidth = "1Gbps",
Location = "EqSe2-EQ",
});
var exampleConnectionAssociation = new Aws.DirectConnect.ConnectionAssociation("exampleConnectionAssociation", new()
{
ConnectionId = exampleConnection.Id,
LagId = exampleLinkAggregationGroup.Id,
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/directconnect"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleConnection, err := directconnect.NewConnection(ctx, "exampleConnection", &directconnect.ConnectionArgs{
Bandwidth: pulumi.String("1Gbps"),
Location: pulumi.String("EqSe2-EQ"),
})
if err != nil {
return err
}
exampleLinkAggregationGroup, err := directconnect.NewLinkAggregationGroup(ctx, "exampleLinkAggregationGroup", &directconnect.LinkAggregationGroupArgs{
ConnectionsBandwidth: pulumi.String("1Gbps"),
Location: pulumi.String("EqSe2-EQ"),
})
if err != nil {
return err
}
_, err = directconnect.NewConnectionAssociation(ctx, "exampleConnectionAssociation", &directconnect.ConnectionAssociationArgs{
ConnectionId: exampleConnection.ID(),
LagId: exampleLinkAggregationGroup.ID(),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.directconnect.Connection;
import com.pulumi.aws.directconnect.ConnectionArgs;
import com.pulumi.aws.directconnect.LinkAggregationGroup;
import com.pulumi.aws.directconnect.LinkAggregationGroupArgs;
import com.pulumi.aws.directconnect.ConnectionAssociation;
import com.pulumi.aws.directconnect.ConnectionAssociationArgs;
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) {
var exampleConnection = new Connection("exampleConnection", ConnectionArgs.builder()
.bandwidth("1Gbps")
.location("EqSe2-EQ")
.build());
var exampleLinkAggregationGroup = new LinkAggregationGroup("exampleLinkAggregationGroup", LinkAggregationGroupArgs.builder()
.connectionsBandwidth("1Gbps")
.location("EqSe2-EQ")
.build());
var exampleConnectionAssociation = new ConnectionAssociation("exampleConnectionAssociation", ConnectionAssociationArgs.builder()
.connectionId(exampleConnection.id())
.lagId(exampleLinkAggregationGroup.id())
.build());
}
}
import pulumi
import pulumi_aws as aws
example_connection = aws.directconnect.Connection("exampleConnection",
bandwidth="1Gbps",
location="EqSe2-EQ")
example_link_aggregation_group = aws.directconnect.LinkAggregationGroup("exampleLinkAggregationGroup",
connections_bandwidth="1Gbps",
location="EqSe2-EQ")
example_connection_association = aws.directconnect.ConnectionAssociation("exampleConnectionAssociation",
connection_id=example_connection.id,
lag_id=example_link_aggregation_group.id)
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const exampleConnection = new aws.directconnect.Connection("exampleConnection", {
bandwidth: "1Gbps",
location: "EqSe2-EQ",
});
const exampleLinkAggregationGroup = new aws.directconnect.LinkAggregationGroup("exampleLinkAggregationGroup", {
connectionsBandwidth: "1Gbps",
location: "EqSe2-EQ",
});
const exampleConnectionAssociation = new aws.directconnect.ConnectionAssociation("exampleConnectionAssociation", {
connectionId: exampleConnection.id,
lagId: exampleLinkAggregationGroup.id,
});
resources:
exampleConnection:
type: aws:directconnect:Connection
properties:
bandwidth: 1Gbps
location: EqSe2-EQ
exampleLinkAggregationGroup:
type: aws:directconnect:LinkAggregationGroup
properties:
connectionsBandwidth: 1Gbps
location: EqSe2-EQ
exampleConnectionAssociation:
type: aws:directconnect:ConnectionAssociation
properties:
connectionId: ${exampleConnection.id}
lagId: ${exampleLinkAggregationGroup.id}
Create ConnectionAssociation Resource
new ConnectionAssociation(name: string, args: ConnectionAssociationArgs, opts?: CustomResourceOptions);
@overload
def ConnectionAssociation(resource_name: str,
opts: Optional[ResourceOptions] = None,
connection_id: Optional[str] = None,
lag_id: Optional[str] = None)
@overload
def ConnectionAssociation(resource_name: str,
args: ConnectionAssociationArgs,
opts: Optional[ResourceOptions] = None)
func NewConnectionAssociation(ctx *Context, name string, args ConnectionAssociationArgs, opts ...ResourceOption) (*ConnectionAssociation, error)
public ConnectionAssociation(string name, ConnectionAssociationArgs args, CustomResourceOptions? opts = null)
public ConnectionAssociation(String name, ConnectionAssociationArgs args)
public ConnectionAssociation(String name, ConnectionAssociationArgs args, CustomResourceOptions options)
type: aws:directconnect:ConnectionAssociation
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ConnectionAssociationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ConnectionAssociationArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ConnectionAssociationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ConnectionAssociationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ConnectionAssociationArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
ConnectionAssociation Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The ConnectionAssociation resource accepts the following input properties:
- Connection
Id string The ID of the connection.
- Lag
Id string The ID of the LAG with which to associate the connection.
- Connection
Id string The ID of the connection.
- Lag
Id string The ID of the LAG with which to associate the connection.
- connection
Id String The ID of the connection.
- lag
Id String The ID of the LAG with which to associate the connection.
- connection
Id string The ID of the connection.
- lag
Id string The ID of the LAG with which to associate the connection.
- connection_
id str The ID of the connection.
- lag_
id str The ID of the LAG with which to associate the connection.
- connection
Id String The ID of the connection.
- lag
Id String The ID of the LAG with which to associate the connection.
Outputs
All input properties are implicitly available as output properties. Additionally, the ConnectionAssociation resource produces the following output properties:
- Id string
The provider-assigned unique ID for this managed resource.
- Id string
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
- id string
The provider-assigned unique ID for this managed resource.
- id str
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
Look up Existing ConnectionAssociation Resource
Get an existing ConnectionAssociation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: ConnectionAssociationState, opts?: CustomResourceOptions): ConnectionAssociation
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
connection_id: Optional[str] = None,
lag_id: Optional[str] = None) -> ConnectionAssociation
func GetConnectionAssociation(ctx *Context, name string, id IDInput, state *ConnectionAssociationState, opts ...ResourceOption) (*ConnectionAssociation, error)
public static ConnectionAssociation Get(string name, Input<string> id, ConnectionAssociationState? state, CustomResourceOptions? opts = null)
public static ConnectionAssociation get(String name, Output<String> id, ConnectionAssociationState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Connection
Id string The ID of the connection.
- Lag
Id string The ID of the LAG with which to associate the connection.
- Connection
Id string The ID of the connection.
- Lag
Id string The ID of the LAG with which to associate the connection.
- connection
Id String The ID of the connection.
- lag
Id String The ID of the LAG with which to associate the connection.
- connection
Id string The ID of the connection.
- lag
Id string The ID of the LAG with which to associate the connection.
- connection_
id str The ID of the connection.
- lag_
id str The ID of the LAG with which to associate the connection.
- connection
Id String The ID of the connection.
- lag
Id String The ID of the LAG with which to associate the connection.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
aws
Terraform Provider.