{
"type": "amazon-ebs",
"instance_type": "t2.micro",
....
....
"ssh_username": "packer"
}
I am might be missing something I think, What is the default packer root user password if not set on build ? Thanks in advance
There is no such thing. Most Amazon AMI's uses cloud-init to retrieve a public ssh key that it will allow the default user to login with, this user will have password less sudo rights. The default user for Amazon Linux is ec2-user
and for Ubuntu it's ubuntu
.
If you only specify ssh_username
in your packer template Packer will create a temporary keypair that it will use during provisioning.
You should probably read the AWS EC2 docs, especially AWS User Guide - EC2 Key Pairs