Skip to content

syniol/aws-cdk-docker-golang

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

AWS CDK Golang Docker Skeleton

This could be used as a base for any new AWS CDK project. It uses Docker dind as a base image & it includes a latest installation of following software:

  • nodejs
  • npm
  • Go
  • AWS CLI

It runs in a privileged mode due to use of docker inside the docker container. This allows CDK to build and publish docker images or synthesis Lambda's container runtime.

Useful Makefile Commands

There is a makefile at the root of this project, this would make running docker-compose.yml easier.

  • make: Builds docker images (it ignores cached image & existing container)
  • make up: Creates and runs docker container for cdk
  • make down: Stops & Removes cdk container
  • make cdk: Enter cdk container

Useful CDK Commands

Start a new CDK project using Golang inside the cdk container using make cdk and then you could run all cdk commands; including the ones demonstrated below.

mkdir deploy
cd deploy
cdk init app --language go

Links

Credits