CfnHostedZonePropsMixin

class aws_cdk.mixins_preview.aws_route53.mixins.CfnHostedZonePropsMixin(props, *, strategy=None)

Bases: Mixin

Creates a new public or private hosted zone.

You create records in a public hosted zone to define how you want to route traffic on the internet for a domain, such as example.com, and its subdomains (apex.example.com, acme.example.com). You create records in a private hosted zone to define how you want to route traffic for a domain and its subdomains within one or more Amazon Virtual Private Clouds (Amazon VPCs). .. epigraph:

You can't convert a public hosted zone to a private hosted zone or vice versa. Instead, you must create a new hosted zone with the same name and create new resource record sets.

For more information about charges for hosted zones, see Amazon Route 53 Pricing .

Note the following:

  • You can’t create a hosted zone for a top-level domain (TLD) such as .com.

  • If your domain is registered with a registrar other than Route 53, you must update the name servers with your registrar to make Route 53 the DNS service for the domain. For more information, see Migrating DNS Service for an Existing Domain to Amazon Route 53 in the Amazon Route 53 Developer Guide .

When you submit a CreateHostedZone request, the initial status of the hosted zone is PENDING . For public hosted zones, this means that the NS and SOA records are not yet available on all Route 53 DNS servers. When the NS and SOA records are available, the status of the zone changes to INSYNC .

The CreateHostedZone request requires the caller to have an ec2:DescribeVpcs permission. .. epigraph:

When creating private hosted zones, the Amazon VPC must belong to the same partition where the hosted zone is created. A partition is a group of AWS Regions . Each AWS account is scoped to one partition.

The following are the supported partitions:

- ``aws`` - AWS Regions
- ``aws-cn`` - China Regions
- ``aws-us-gov`` - AWS GovCloud (US) Region

For more information, see `Access Management <https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html>`_ in the *AWS General Reference* .
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-route53-hostedzone.html

CloudformationResource:

AWS::Route53::HostedZone

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_route53 import mixins as route53_mixins

cfn_hosted_zone_props_mixin = route53_mixins.CfnHostedZonePropsMixin(route53_mixins.CfnHostedZoneMixinProps(
    hosted_zone_config=route53_mixins.CfnHostedZonePropsMixin.HostedZoneConfigProperty(
        comment="comment"
    ),
    hosted_zone_tags=[route53_mixins.CfnHostedZonePropsMixin.HostedZoneTagProperty(
        key="key",
        value="value"
    )],
    name="name",
    query_logging_config=route53_mixins.CfnHostedZonePropsMixin.QueryLoggingConfigProperty(
        cloud_watch_logs_log_group_arn="cloudWatchLogsLogGroupArn"
    ),
    vpcs=[route53_mixins.CfnHostedZonePropsMixin.VPCProperty(
        vpc_id="vpcId",
        vpc_region="vpcRegion"
    )]
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::Route53::HostedZone.

Parameters:
  • props (Union[CfnHostedZoneMixinProps, Dict[str, Any]]) – L1 properties to apply.

  • strategy (Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['hostedZoneConfig', 'hostedZoneTags', 'name', 'queryLoggingConfig', 'vpcs']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

HostedZoneConfigProperty

class CfnHostedZonePropsMixin.HostedZoneConfigProperty(*, comment=None)

Bases: object

A complex type that contains an optional comment about your hosted zone.

If you don’t want to specify a comment, omit both the HostedZoneConfig and Comment elements.

Parameters:

comment (Optional[str]) – Any comments that you want to include about the hosted zone.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-hostedzoneconfig.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_route53 import mixins as route53_mixins

hosted_zone_config_property = route53_mixins.CfnHostedZonePropsMixin.HostedZoneConfigProperty(
    comment="comment"
)

Attributes

comment

Any comments that you want to include about the hosted zone.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-hostedzoneconfig.html#cfn-route53-hostedzone-hostedzoneconfig-comment

HostedZoneTagProperty

class CfnHostedZonePropsMixin.HostedZoneTagProperty(*, key=None, value=None)

Bases: object

A complex type that contains information about a tag that you want to add or edit for the specified health check or hosted zone.

Parameters:
  • key (Optional[str]) – The value of Key depends on the operation that you want to perform:. - Add a tag to a health check or hosted zone : Key is the name that you want to give the new tag. - Edit a tag : Key is the name of the tag that you want to change the Value for. - Delete a key : Key is the name of the tag you want to remove. - Give a name to a health check : Edit the default Name tag. In the Amazon Route 53 console, the list of your health checks includes a Name column that lets you see the name that you’ve given to each health check.

  • value (Optional[str]) – The value of Value depends on the operation that you want to perform:. - Add a tag to a health check or hosted zone : Value is the value that you want to give the new tag. - Edit a tag : Value is the new value that you want to assign the tag.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-hostedzonetag.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_route53 import mixins as route53_mixins

hosted_zone_tag_property = route53_mixins.CfnHostedZonePropsMixin.HostedZoneTagProperty(
    key="key",
    value="value"
)

Attributes

key

.

  • Add a tag to a health check or hosted zone : Key is the name that you want to give the new tag.

  • Edit a tag : Key is the name of the tag that you want to change the Value for.

  • Delete a key : Key is the name of the tag you want to remove.

  • Give a name to a health check : Edit the default Name tag. In the Amazon Route 53 console, the list of your health checks includes a Name column that lets you see the name that you’ve given to each health check.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-hostedzonetag.html#cfn-route53-hostedzone-hostedzonetag-key

Type:

The value of Key depends on the operation that you want to perform

value

.

  • Add a tag to a health check or hosted zone : Value is the value that you want to give the new tag.

  • Edit a tag : Value is the new value that you want to assign the tag.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-hostedzonetag.html#cfn-route53-hostedzone-hostedzonetag-value

Type:

The value of Value depends on the operation that you want to perform

QueryLoggingConfigProperty

class CfnHostedZonePropsMixin.QueryLoggingConfigProperty(*, cloud_watch_logs_log_group_arn=None)

Bases: object

A complex type that contains information about a configuration for DNS query logging.

Parameters:

cloud_watch_logs_log_group_arn (Optional[str]) – The Amazon Resource Name (ARN) of the CloudWatch Logs log group that Amazon Route 53 is publishing logs to.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-queryloggingconfig.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_route53 import mixins as route53_mixins

query_logging_config_property = route53_mixins.CfnHostedZonePropsMixin.QueryLoggingConfigProperty(
    cloud_watch_logs_log_group_arn="cloudWatchLogsLogGroupArn"
)

Attributes

cloud_watch_logs_log_group_arn

The Amazon Resource Name (ARN) of the CloudWatch Logs log group that Amazon Route 53 is publishing logs to.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-queryloggingconfig.html#cfn-route53-hostedzone-queryloggingconfig-cloudwatchlogsloggrouparn

VPCProperty

class CfnHostedZonePropsMixin.VPCProperty(*, vpc_id=None, vpc_region=None)

Bases: object

Private hosted zones only: A complex type that contains information about an Amazon VPC.

Route 53 Resolver uses the records in the private hosted zone to route traffic in that VPC. .. epigraph:

For public hosted zones, omit ``VPCs`` , ``VPCId`` , and ``VPCRegion`` .
Parameters:
  • vpc_id (Optional[str]) – Private hosted zones only: The ID of an Amazon VPC. .. epigraph:: For public hosted zones, omit VPCs , VPCId , and VPCRegion .

  • vpc_region (Optional[str]) – Private hosted zones only: The region that an Amazon VPC was created in. .. epigraph:: For public hosted zones, omit VPCs , VPCId , and VPCRegion .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-vpc.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_route53 import mixins as route53_mixins

v_pCProperty = route53_mixins.CfnHostedZonePropsMixin.VPCProperty(
    vpc_id="vpcId",
    vpc_region="vpcRegion"
)

Attributes

vpc_id
  • The ID of an Amazon VPC.

For public hosted zones, omit VPCs , VPCId , and VPCRegion .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-vpc.html#cfn-route53-hostedzone-vpc-vpcid

Type:

*Private hosted zones only

vpc_region
  • The region that an Amazon VPC was created in.

For public hosted zones, omit VPCs , VPCId , and VPCRegion .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-hostedzone-vpc.html#cfn-route53-hostedzone-vpc-vpcregion

Type:

*Private hosted zones only