Skip to content

VPC Lattice service custom domain name

0

Dear Team - As per, https://docs.aws.amazon.com/vpc-lattice/latest/ug/service-custom-domain-name.html#dns-associate-custom,

If you'd prefer to use a custom domain name for your service, such as www.parking.example.com instead of the VPC Lattice generated DNS name, you can configure it when you create a VPC Lattice service. When a client makes a request using your custom domain name, the DNS server resolves it to the VPC Lattice generated domain name. However, this happens only if you map your custom domain name to the VPC Lattice generated domain name with a CNAME record to route queries to your service

Scenario ->

  1. During VPC Lattice service (HTTP-80) creation, i selected default VPC lattice generated domain name
  2. On consumer VPC, i created PHZ parking.example.com and added record www CNAME as Lattice service generated DNS Name

In above scenario, what's the use case of custom domain name ? as i can still access lattice service www.parking.example.com without selecting custom domain name during lattice service creation.

asked a year ago389 views

2 Answers
1

Hello.

Custom domains are also used when encrypting communications using TLS.
Therefore, if you want to set up encryption with TLS, you will need to set up a domain when creating it.
If you do not specify a custom domain, you will not be able to add a TLS listener.
https://docs.aws.amazon.com/vpc-lattice/latest/ug/tls-listeners.html

If you do not specify a custom domain, the TLS listener will be grayed out and cannot be added, as shown in the image below.
a

EXPERT

answered a year ago

0
Accepted Answer

You're correct in your observation, and it's a good question. The scenario you've described does indeed allow you to use a custom domain name (www.parking.example.com) to access your VPC Lattice service without explicitly configuring a custom domain name during the service creation. However, there are some important distinctions and benefits to using the custom domain name feature provided by VPC Lattice:

  1. Official Configuration: When you configure a custom domain name during VPC Lattice service creation, it becomes an official part of the service configuration. This means VPC Lattice is aware of and can manage this custom domain, which can be beneficial for service management and potential future features.

  2. Validation: VPC Lattice performs validation checks when you configure a custom domain name. This helps ensure that the domain name meets the required criteria and is properly set up, potentially avoiding issues down the line.

  3. HTTPS Support: If you want to receive HTTPS requests on your custom domain, you must provide your own SSL/TLS certificate in AWS Certificate Manager when configuring the custom domain name through VPC Lattice. This integration is more seamless when done during service creation.

  4. Consistency and Best Practices: Using the built-in custom domain name feature ensures you're following AWS best practices for VPC Lattice configuration.

  5. Future-proofing: While your current setup works, using the official custom domain name feature may provide better compatibility with future VPC Lattice features or integrations.

  6. Simplified Management: Having the custom domain as part of the VPC Lattice service configuration can make it easier to manage and track, especially in complex environments with multiple services.

  7. Potential Performance Optimization: Although not explicitly stated, there might be internal optimizations when using the official custom domain name feature.

While your current setup achieves the desired result, using the custom domain name feature during service creation provides a more integrated and potentially more robust solution. However, if your current setup meets your needs and you're not requiring HTTPS support or anticipating complex future requirements, it can continue to work effectively.
Sources
Configure a custom domain name for your VPC Lattice service - Amazon VPC Lattice
Amazon VPC Lattice Reference Architectures - Amazon VPC Lattice Reference Architectures
Amazon VPC Lattice DNS migration strategies and best practices | Networking & Content Delivery

answered a year ago

EXPERT

reviewed a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.