Cloudformation: How to Reference a DNS IP address for DHCPOptions, why does

0

Just trying to create a simple DHCP option set to me EC2 instances have a default domain..

but when i just input the ip address as a test ( not even referencing) it is telling me it wants a string

DHCPTest:
Type: AWS::EC2::DHCPOptions
Properties:
DomainName: test.com
DomainNameServers: "10.0.0.1"

Value of property DomainNameServers must be of type List of String

The domain name Servers will be a reference to an EC2 created IP address

but i can just go into the front end and simple type in that ip address and it saves fine... i dont want to use the amazon provided DNS.. how can i create the DHCP with the ip addresses? This should be simple

已提問 5 年前檢視次數 387 次
1 個回答
0

[SOLVED] Its a LIST of string, not a string. Reading Comprehension helps

If anyone else runs into this, the syntax is:

DomainNameServers:
- !getAtt AdInstance.PrivateIp

works, needs to be listed with the dashes

Edited by: JWhitcomb-AWS on Jun 17, 2019 9:52 AM

Edited by: JWhitcomb-AWS on Jun 17, 2019 9:53 AM

Edited by: JWhitcomb-AWS on Jun 17, 2019 9:53 AM

已回答 5 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南