EC2 instance has no public DNS

后端 未结 18 1354
-上瘾入骨i
-上瘾入骨i 2020-12-22 16:26

A guy I work with gave me the EC2 credentials to log onto his EC2 console. I was not the one who set it up. Some of the instances show a public dns name and others have a bl

18条回答
  •  南方客
    南方客 (楼主)
    2020-12-22 17:08

    For those using CloudFormation, the key properties are EnableDnsSupport and EnableDnsHostnames which should be set to true

    VPC: {
        Type: 'AWS::EC2::VPC',
        Properties: {
          CidrBlock: '10.0.0.0/16',
          EnableDnsSupport: true,
          EnableDnsHostnames: true,
          InstanceTenancy: 'default',
          Tags: [
            {
              Key: 'env',
              Value: 'dev'
            }]
        }
      }
    

提交回复
热议问题