The Example for Continuous Deployment with Github Actions and AWS ECR uses a GitHub Deployment to trigger releases of tagged docker images. Using GitHub Actions, a task can be triggered for every created deployment.
Create a file in .github/workflows
to store the configuration:
name: Release
on: deployment
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Set $VERSION variable
id: version
run: echo ::set-output name=VERSION::$(echo $GITHUB_REF | cut -d / -f 3)
- name: Update your application
run: echo "Use new tagged image ${{ steps.version.outputs.VERSION }}"
- name: Update Deployment (success)
if: success()
uses: chrnorm/deployment-status@releases/v1
with:
token: ${{ secrets.CUSTOM_GITHUB_TOKEN }}
state: "success"
deployment_id: ${{ github.event.deployment.id }}
- name: Update Deployment (failure)
if: failure()
uses: chrnorm/deployment-status@releases/v1
with:
token: ${{ secrets.CUSTOM_GITHUB_TOKEN }}
state: "failure"
deployment_id: ${{ github.event.deployment.id }}
Together with Continuous Deployment with Github Actions and AWS ECR and Semantic Releases With Github Actions this is a nice Event-Driven Delivery process.
-
December 17 th, 2020
486 Words
To decouple services on AWS, it’s a common pattern to use Amazon SQS and Amazon SNS. With AWS Key Management Service, you can encrypt the messages stored in the SNS topic and SQS queue. For the AWS Cloud Development Kit using TypeScript, you can easily create an architecture for secure message processing.
-
December 11 th, 2020
270 Words
With AWS CloudFormation StackSets you can deploy a CloudFormation template to multiple AWS Accounts or AWS Regions. You can use the AWS Management Console, the AWS CLI, or CloudFormation to use StackSets. Before using StackSets, you need to configure specific IAM roles to be used with CloudFormation StackSets.
-
December 7 th, 2020
380 Words
Most people only use Amazon API Gateway as an HTTP interface to invoke AWS Lambda functions. But, the service has way more to offer. For example, you can easily create an HTTP interface for nearly any AWS Service; not only AWS Lambda. Based on the previous post, on how to create a State Machine with AWS Step Functions and AWS Cloud Development Kit, this post describes how to create an HTTP interface to start an execution of a State Machine using the AWS CDK.
-
December 7 th, 2020
327 Words
Most people know Amazon API Gateway from using it to build HTTP interfaces for AWS Lambda functions. But, in general, you can use API Gateway to call a variety AWS APIs using HTTPS. This post shows how to create an HTTPS interface for Amazon SQS using the AWS Cloud Development Kit.
-
December 6 th, 2020
435 Words
With AWS Step Functions, you can easily orchestrate serverless functions and sequence them with other AWS services to a bundle application. You can create AWS Step Functions with CloudFormation, the AWS Cloud Development Kit, or - of course - using the visual interface available in the AWS Management Console. This post shows how to orchestrate AWS Lambda functions to a simple State Machine using AWS Step Functions.
-
December 6 th, 2020
463 Words
Using the AWS Cloud Development Kit, deploying a AWS Lambda function using Docker container images is pure gold. The installation of dependencies for Lambda functions always stressed me out. Regardless of using Node.js or Python, managing dependencies for AWS Lambda was never fun.
-
December 5 th, 2020
195 Words
The AWS Cloud Development Kit supports building docker images for AWS Lambda. With the most recent version, the CDK builds your docker images if needed and can push the image directly to AWS Elastic Container Registry. Personally, I think this is a great feature. With supporting docker images, AWS Lambda has immutable deployment artifacts!