Skip to content

ausias-armesto/uchicago-packer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The Univerisity of Chicago - Devops Course - AWS MYSQL AMI

Introduction

This repository has been created as part of the contents for the Devops Course at the The Univerisity of Chicago as an Teacher Assistant.

The purpose of this repository is to show an example of how to use the Packer technology to create AWS AMI images. The AMI generated is based on an Amazon Linux 2 OS with MySql Community 5.7

Important

Recall to delete the AMI and it associated snapshot to not incur in undesirable costs once you have finished testing with it

Prerequisites

  • Installed AWS Cli 2.2.12
  • Installed Packer 1.7.2

Commands

Run the packer build, which will take a few minutes:

packer build --debug packer.json
AMI_ID=$(jq -r '.builds[-1].artifact_id' manifest.json | cut -d ":" -f2)  

Github Actions

On every push to branch master or develop a new image is created, with some predefined values. It has been assumed that the develop branch would hold the 'dev' environment and the master branch would hold the 'pre' environment. The image is generated in different regions (eu-west-1, eu-west-2) depending on the branch

To be able to run successfully, remind that you need to have configured on your forked repository the following secrets with its corresponding values to connect to AWS:

  • AWS_ACCESS_KEY_ID
  • AWS_SECRET_ACCESS_KEY

See them on Github Actions

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages