Skip to content

Instantly share code, notes, and snippets.

@takakabe
Created October 12, 2017 10:40
Embed
What would you like to do?
Resources:
Instance:
Type: "AWS::EC2::Instance"
Properties:
AvailabilityZone: "ap-northeast-1a"
ImageId: "ami-4af5022c"
InstanceType: "t2.micro"
KeyName: "キーペア名"
PrivateIpAddress: "192.140.1.1"
SecurityGroupIds:
- "sg-XXXXXXXX"
SubnetId: "subnet-XXXXXXXX"
ElasticIP:
Type: "AWS::EC2::EIP"
Properties:
Domain: vpc
ElasticIPAssociate:
Type: AWS::EC2::EIPAssociation
Properties:
AllocationId: !GetAtt ElasticIP.AllocationId
InstanceId: !Ref Instance
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment