Skip to content

Example of infrastructure as code using Ansible, Packer and Terraform tools

Notifications You must be signed in to change notification settings

xserrat/company-infrastructure

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Company Infrastructure

Install Ansible roles

$ ansible-galaxy install -r ansible/galaxy/requirements.yml

Building provisioned aws AMI using Packer + Ansible

  • Create the credentials.json file under packer/amazon with the following format:
{
  "aws_access_key": "<your-aws-access-key>",
  "aws_secret_key": "<your-aws-secret-key>"
}
  • Execute packer:
packer build -var-file=packer/amazon/credentials.json -var-file=packer/amazon/variables.json packer/amazon/ubuntu/frontend/base_ami.json
  • Create an EC2 instance manually using the created AMI.

  • Access to EC2 instance via SSH using .pem to test installation

ssh -i aws.pem ubuntu@<ip-instance>

About

Example of infrastructure as code using Ansible, Packer and Terraform tools

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published