

This is the new *CloudFormation Template Reference Guide*. Please update your bookmarks and links. For help getting started with CloudFormation, see the [AWS CloudFormation User Guide](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/Welcome.html).

# AWS::EC2::RouteServerPeer
<a name="aws-resource-ec2-routeserverpeer"></a>

Specifies a BGP peer configuration for a route server endpoint.

A route server peer is a session between a route server endpoint and the device deployed in AWS (such as a firewall appliance or other network security function running on an EC2 instance).

## Syntax
<a name="aws-resource-ec2-routeserverpeer-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-resource-ec2-routeserverpeer-syntax.json"></a>

```
{
  "Type" : "AWS::EC2::RouteServerPeer",
  "Properties" : {
      "[BgpOptions](#cfn-ec2-routeserverpeer-bgpoptions)" : BgpOptions,
      "[PeerAddress](#cfn-ec2-routeserverpeer-peeraddress)" : String,
      "[RouteServerEndpointId](#cfn-ec2-routeserverpeer-routeserverendpointid)" : String,
      "[Tags](#cfn-ec2-routeserverpeer-tags)" : [ Tag, ... ]
    }
}
```

### YAML
<a name="aws-resource-ec2-routeserverpeer-syntax.yaml"></a>

```
Type: AWS::EC2::RouteServerPeer
Properties:
  [BgpOptions](#cfn-ec2-routeserverpeer-bgpoptions): 
    BgpOptions
  [PeerAddress](#cfn-ec2-routeserverpeer-peeraddress): String
  [RouteServerEndpointId](#cfn-ec2-routeserverpeer-routeserverendpointid): String
  [Tags](#cfn-ec2-routeserverpeer-tags): 
    - Tag
```

## Properties
<a name="aws-resource-ec2-routeserverpeer-properties"></a>

`BgpOptions`  <a name="cfn-ec2-routeserverpeer-bgpoptions"></a>
The BGP configuration options for this peer, including ASN (Autonomous System Number) and BFD (Bidrectional Forwarding Detection) settings.  
*Required*: Yes  
*Type*: [BgpOptions](aws-properties-ec2-routeserverpeer-bgpoptions.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`PeerAddress`  <a name="cfn-ec2-routeserverpeer-peeraddress"></a>
The IPv4 address of the peer device.  
*Required*: Yes  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`RouteServerEndpointId`  <a name="cfn-ec2-routeserverpeer-routeserverendpointid"></a>
The ID of the route server endpoint associated with this peer.  
*Required*: Yes  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Tags`  <a name="cfn-ec2-routeserverpeer-tags"></a>
Any tags assigned to the route server peer.  
*Required*: No  
*Type*: Array of [Tag](aws-properties-ec2-routeserverpeer-tag.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

## Return values
<a name="aws-resource-ec2-routeserverpeer-return-values"></a>

### Ref
<a name="aws-resource-ec2-routeserverpeer-return-values-ref"></a>

When you pass the logical ID of this resource to the intrinsic `Ref` function, `Ref` returns the peer ID.

### Fn::GetAtt
<a name="aws-resource-ec2-routeserverpeer-return-values-fn--getatt"></a>

The `Fn::GetAtt` intrinsic function returns a value for a specified attribute of this type. The following are the available attributes and sample return values.

For more information about using the `Fn::GetAtt` intrinsic function, see [https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-getatt.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-getatt.html).

#### 
<a name="aws-resource-ec2-routeserverpeer-return-values-fn--getatt-fn--getatt"></a>

`Arn`  <a name="Arn-fn::getatt"></a>
The ARN of the route server peer.

`EndpointEniAddress`  <a name="EndpointEniAddress-fn::getatt"></a>
The IP address of the Elastic network interface for the route server endpoint.

`EndpointEniId`  <a name="EndpointEniId-fn::getatt"></a>
The ID of the Elastic network interface for the route server endpoint.

`Id`  <a name="Id-fn::getatt"></a>
The ID of the route server peer.

`RouteServerId`  <a name="RouteServerId-fn::getatt"></a>
The ID of the route server associated with this peer.

`SubnetId`  <a name="SubnetId-fn::getatt"></a>
The ID of the subnet containing the route server peer.

`VpcId`  <a name="VpcId-fn::getatt"></a>
The ID of the VPC containing the route server peer.

# AWS::EC2::RouteServerPeer BgpOptions
<a name="aws-properties-ec2-routeserverpeer-bgpoptions"></a>

The BGP configuration options for this peer, including ASN (Autonomous System Number) and BFD (Bidrectional Forwarding Detection) settings.

## Syntax
<a name="aws-properties-ec2-routeserverpeer-bgpoptions-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-ec2-routeserverpeer-bgpoptions-syntax.json"></a>

```
{
  "[PeerAsn](#cfn-ec2-routeserverpeer-bgpoptions-peerasn)" : Integer,
  "[PeerLivenessDetection](#cfn-ec2-routeserverpeer-bgpoptions-peerlivenessdetection)" : String
}
```

### YAML
<a name="aws-properties-ec2-routeserverpeer-bgpoptions-syntax.yaml"></a>

```
  [PeerAsn](#cfn-ec2-routeserverpeer-bgpoptions-peerasn): Integer
  [PeerLivenessDetection](#cfn-ec2-routeserverpeer-bgpoptions-peerlivenessdetection): String
```

## Properties
<a name="aws-properties-ec2-routeserverpeer-bgpoptions-properties"></a>

`PeerAsn`  <a name="cfn-ec2-routeserverpeer-bgpoptions-peerasn"></a>
The Border Gateway Protocol (BGP) Autonomous System Number (ASN) for the appliance. Valid values are from 1 to 4294967295. We recommend using a private ASN in the 64512–65534 (16-bit ASN) or 4200000000–4294967294 (32-bit ASN) range.  
*Required*: No  
*Type*: Integer  
*Minimum*: `1`  
*Maximum*: `4294967294`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`PeerLivenessDetection`  <a name="cfn-ec2-routeserverpeer-bgpoptions-peerlivenessdetection"></a>
The liveness detection protocol used for the BGP peer.  
The requested liveness detection protocol for the BGP peer.  
+ `bgp-keepalive`: The standard BGP keep alive mechanism ([RFC4271](https://www.rfc-editor.org/rfc/rfc4271#page-21)) that is stable but may take longer to fail-over in cases of network impact or router failure.
+ `bfd`: An additional Bidirectional Forwarding Detection (BFD) protocol ([RFC5880](https://www.rfc-editor.org/rfc/rfc5880)) that enables fast failover by using more sensitive liveness detection.
Defaults to `bgp-keepalive`.  
*Required*: No  
*Type*: String  
*Allowed values*: `bfd | bgp-keepalive`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EC2::RouteServerPeer Tag
<a name="aws-properties-ec2-routeserverpeer-tag"></a>

Describes a tag.

## Syntax
<a name="aws-properties-ec2-routeserverpeer-tag-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-ec2-routeserverpeer-tag-syntax.json"></a>

```
{
  "[Key](#cfn-ec2-routeserverpeer-tag-key)" : String,
  "[Value](#cfn-ec2-routeserverpeer-tag-value)" : String
}
```

### YAML
<a name="aws-properties-ec2-routeserverpeer-tag-syntax.yaml"></a>

```
  [Key](#cfn-ec2-routeserverpeer-tag-key): String
  [Value](#cfn-ec2-routeserverpeer-tag-value): String
```

## Properties
<a name="aws-properties-ec2-routeserverpeer-tag-properties"></a>

`Key`  <a name="cfn-ec2-routeserverpeer-tag-key"></a>
The key of the tag.  
Constraints: Tag keys are case-sensitive and accept a maximum of 127 Unicode characters. May not begin with `aws:`.  
*Required*: Yes  
*Type*: String  
*Minimum*: `1`  
*Maximum*: `128`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Value`  <a name="cfn-ec2-routeserverpeer-tag-value"></a>
The value of the tag.  
Constraints: Tag values are case-sensitive and accept a maximum of 256 Unicode characters.  
*Required*: Yes  
*Type*: String  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)