Skip to content

Manage multiple CloudFormation ymls with Github Actions and python script

Notifications You must be signed in to change notification settings

LittleWat/cfn-github-action-sample

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cfn-github-action-sample

Cloudformation with Github Actions sample repository.

japanese article -> ぼくのかんがえたさいきょうのGithub Actionsで複数のCloudFormationファイルをCI/CDする方法 - Qiita

You can

  • Run CI(linter, dryrun) and see the result on pull request
    • example: #2
  • Deploy easily;
    • If you force-push to dev-release or stg-release branch will deploy to dev or stg environment like the command below;
      • git push origin HEAD:dev-release -f
    • prd-release is dangerous, so you need to make a pull request to deploy to prd environment.

Setup

You need to create s3 bucket to put yaml files.

The bucket name is like this;

  • ${ENV}-${PROJECT_NAME}-infra-cfn

Run Locally

  1. Download direnv

  2. Copy .env.template to .env and edit .env based on your setting

  3. Then run dryrun,

python deploy.py --dryrun

if dryrun result is ok, then deploy

python deploy.py

About

Manage multiple CloudFormation ymls with Github Actions and python script

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages