This is a project that deploys Hasura along with Aurora Serverless using AWS CDK.
It creates:
- the cluster and the database in the default VPC.
- an ALB over the hasura instance(s)
- a bunch of private VPC endpoints.
It doesn't create a NAT Gateway to reduce overall cost.
See the images/hasura-graphql-engine/ for the Dockerfile and custom run script.
The main stack is in lib/hasura-cdk-stack.ts
This implementation takes inspiration from the work of Gordon Johnson (@elgordino) and his Lineup Ninja Hasura CDK presentation.
npm run build
compile typescript to jsnpm run watch
watch for changes and compilenpm run test
perform the jest unit testscdk deploy
deploy this stack to your default AWS account/regioncdk diff
compare deployed stack with current statecdk synth
emits the synthesized CloudFormation template