Skip to content

widdix/aws-cloudformation-github-deploy

Use this GitHub Action with your project

Add this Action to an existing workflow or create a new one.

View on Marketplace
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code
This branch is 17 commits ahead, 52 commits behind aws-actions:master.

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Deploy CloudFormation Stack(s) for GitHub Actions

Deploys AWS CloudFormation stacks.

Usage

To deploy a single stack:

- uses: widdix/aws-cloudformation-github-deploy@v2
  with:
    name: StackA
    template: a.yaml
    parameter-overrides: Param1=a1,Param2=a2

To dedploy multiple stacks in parallel:

- uses: widdix/aws-cloudformation-github-deploy@v2
  with:
    name: |
      StackA
      StackB
    template: |
      a.yaml
      b.yaml
    parameter-overrides: |
      MyParam1=a1,MyParam2=a2
      MyParam1=b1

To dedploy multiple stacks in parallel using the same settings for all stacks:

- uses: widdix/aws-cloudformation-github-deploy@v2
  with:
    name: |
      StackA
      StackB
      StackC
    template: |
      a.yaml
      b.yaml
      c.yaml
    disable-rollback: "1" # applies to all three stacks

To dedploy multiple stacks in parallel passing in no values for a specific stack using a empty line:

- uses: widdix/aws-cloudformation-github-deploy@v2
  with:
    name: |
      StackA
      StackB
      StackC
    template: |
      a.yaml
      b.yaml
      c.yaml
    parameter-overrides: |
      Param1=a1,MyParam2=a2
      
      Param1=c1

The action can be passed a CloudFormation Stack name and a template file. The template file can be a local file existing in the working directory, or a URL to template that exists in an Amazon S3 bucket. It will create the Stack if it does not exist, or create a Change Set to update the Stack.

See action.yml for the full documentation for this action's inputs and outputs.

Example

name: Deploy

on: [push]

jobs:
  deploy:
    name: Deploy
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v3
    - uses: aws-actions/configure-aws-credentials@v1-node16
      with:
        # ...
        aws-region: us-east-1
    - id: core
      uses: widdix/aws-cloudformation-github-deploy@v2
      with:
        name: StackA
        template: a.yaml
        parameter-overrides: Param1=a1,MyParam2=a2
    - uses: widdix/aws-cloudformation-github-deploy@v2
      with:
        name: |
          StackB
          StackC
        template: |
          b.yaml
          c.yaml
        parameter-overrides: |
          
          Param1=${{ steps.core.outputs.StackA_output_AlertTopicArn }}

About

Deploys AWS CloudFormation Stacks

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 98.0%
  • JavaScript 2.0%