Created
January 7, 2016 03:19
-
-
Save lorentzca/f008151de5a8ffbd9ab0 to your computer and use it in GitHub Desktop.
create ami with packer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"variables": { | |
"aws_access_key": "{{env `AWS_ACCESS_KEY_ID`}}", | |
"aws_secret_key": "{{env `AWS_SECRET_ACCESS_KEY`}}" | |
}, | |
"builders": [ | |
{ | |
"type": "amazon-ebs", | |
"access_key": "{{user `aws_access_key`}}", | |
"secret_key": "{{user `aws_secret_key`}}", | |
"region": "ap-northeast-1", | |
"source_ami": "ami-89634988", | |
"instance_type": "t2.micro", | |
"ssh_username": "centos", | |
"ssh_timeout": "10m", | |
"ssh_pty": true, | |
"ami_name": "my_ami {{timestamp}}" | |
} | |
], | |
"provisioners": [ | |
{ | |
"type": "shell", | |
"inline": [ | |
"sudo yum -y update" | |
] | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ami-89634988 : centos7 (official)
export access key 💥
build 🔨
⬇️ ⬇️ ⬇️