cdk-django
jsii
cdk-django | jsii | |
---|---|---|
10 | 33 | |
46 | 2,563 | |
- | 1.0% | |
5.1 | 9.4 | |
6 days ago | 1 day ago | |
TypeScript | TypeScript | |
MIT License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
cdk-django
-
My Infrastructure as Code Rosetta Stone - Deploying the same Django application on AWS ECS Fargate with CDK, Terraform and Pulumi
cdk-django
-
My Infrastructure as Code Rosetta Stone - Deploying the same web application on AWS ECS Fargate with CDK, Terraform and Pulumi
CDK Construct Library: github.com/briancaffey/cdk-django
-
Django AWS CDK deployment
- Another aspect of my approach that I prefer over the other one is using a high-level construct that you publish and then consume in your project. This requires that you write a construct in TypeScript and then publish it to npm or PyPI. I'm working on a construct library for deploying Django apps with CDK called djagno-cdk, and one of the constructs in it uses ECS Fargate: https://github.com/briancaffey/django-cdk/blob/main/src/django-ecs.ts. Ideally you don't have everything in a single construct though, so I like how Mariano is doing that in his project. My Terraform project does a better job at separating layers of the application, so I need to apply that same principle to django-cdk when I get around to working on that project again.
-
My approach to building ad hoc developer environments using AWS ECS, Terraform and GitHub Actions (article link and diagram description in comments)
Sure. My IaC journey actually started out with CloudFormation, and I learned a lot from this reference project: aws-samples/ecs-refarch-cloudformation. Then I picked up CDK when that became available and migrated a project from CloudFormation to CDK. It sounded like a nicer way to handle stacks in a familiar language with lots great one-liners and utility functions and constructs, and it definitely is. I have a similar project written in CDK that is an application/framework-first (Django) approach to learning and doing IaC that you can find here: https://github.com/briancaffey/django-cdk. This implements both ECS and EKS, but my attempts at learning EKS sort of fizzled out for now as I don't have the need to use it, and for the task at hand (running a monolithic Django application on AWS) I think ECS makes a LOT more sense.
-
Basic questions about Django app deployment on AWS
I have an example of doing this here, and I posted about this earlier on this sub https://www.reddit.com/r/django/comments/rj7sj2/deploying_django_applications_to_a_singlenode/
-
Deploying Django applications to a single-node docker swarm cluster on EC2 with AWS Cloud Development Kit (CDK) and GitHub Actions (description, repo links + full article in comments)
I'm not sure what you mean by "architecture", and I'm not sure what is wrong with trying to save money while learning how to do IaC and CI/CD. My thinking is that I can use some of what I learned here in a more robust setup of a Django app that uses ECS, I'm working on that here: https://github.com/briancaffey/django-cdk/blob/main/src/django-ecs.ts.
-
Any examples of custom ecs constructs which builds on the top of ecs patterns
Here is on that I’m working on: https://github.com/briancaffey/django-cdk
-
Ask r/kubernetes: What are you working on this week?
Here's a link to the repo: https://github.com/briancaffey/django-cdk. This library currently offers high level constructs for EKS as well as ECS. I have previously used ECS for most of the containerized web apps I have worked with, so I'm hoping to use this as a way to compare the two orchestration tools for my use case and gather some best practices. This project includes a companion repo that is included as a git submodule that I have been to do live tests/deployments using my construct library.
jsii
-
The Stainless SDK Generator
What about jsii? The technology behind AWS sdks: https://aws.github.io/jsii/
Is Stainless similar, different?
-
AWS Makes Cloud Formation Stack Creation Up to 40% Faster
The libraries for other supported languages of CDK are built as wrappers for underlying JS or maybe TS code via https://github.com/aws/jsii
So all the core CDK code is written first in JS/TS and then stubs for the other languages are added
Unfortunately this is often done without consideration for how the other supported langs actually work, and artefacts of e.g. JS lack of support for kwargs leak through
This is why e.g. the typing in CDK Python is completely broken - pretty much uniformly the concrete types like "Resource" don't implement their corresponding interface like "IResource" (to a type checker)
(There are many other typing niggles like this but that's the most egregious and pervasive one)
At the end of the day, having to explicitly cast concrete types as their interface to satisfy type checker is a minor annoyance, albeit a stupid one that could have been avoided with more care in the core library.
I could live with that, but I encountered so many bugs and issues trying to use CDK on current project that it's now much clearer to me why every company I worked at previously was using Terraform.
Pretty sure some of those issues are ultimately CloudFormation ones. The cumbersome CF > CDK JS > CDK Python stack is great for obfuscating errors and making debugging hard or impossible though.
Pulumi do something similar, albeit with Go as the core language and Terraform underneath. From what I've seen with a little use they have a much more successful result though, Pulumi Python was not a complete mess, and deploys faster and more reliable with better error feedback. I guess they just took more care to get it right.
-
Infrastructure Manager: Provision Google Cloud Resources with Terraform
Every version of the CDK uses an interop layer and runs on top of the Typescript version
https://github.com/aws/jsii
And as far as TF supports services before CFT. Guess which is easier for an AWS employee to do - getting the CF service team to support a new service or just contribute to Terraform’s open source project?
I know of at least one service where the service team introduced the needed APIs and then an employee of AWS wrote the TF provider and contributed to the project before AWS’s own internal team added it to CFT.
Source: former AWS ProServe employee
- JSii allows code in any language to naturally interact with JavaScript classes
-
Cloud, why so difficult? 🤷♀️
To "meet developers where they are" is a beautiful tenet of AWS, and of the CDK, and inspired us to create awesome technology such as JSII and constructs.
-
Automating AWS API gateways v1 REST
Yeah both CDKTF and Pulumi piggyback on JSII, a class translator that supports the languages you've mentioned, which was used as a building base for CDK.
-
New open-source programming language for DevOps engineers by the creator of the CDK
The reason we chose to start with compilation to JavaScript and not some other popular cloud language is because JavaScript is currently one of the most used ones, and in addition, we are using JSII to write our SDK in Typescript and then export it for consumption in other languages, such as Go, Python, Java and others.
- Write SDK “base” in Rust, wrap in other languages?
-
CDKTF Frequently Asked Questions
The CDKTF CLI is implemented in TypeScript. Providers and resources are implemented in TypeScript as well. jsii is used to compile the providers and resources to the supported languages.
- 10 things about AWS CDK
What are some alternatives?
aws-cdk - The AWS Cloud Development Kit is a framework for defining cloud infrastructure in code
Pulumi - Pulumi - Infrastructure as Code in any programming language. Build infrastructure intuitively on any cloud using familiar languages 🚀
pulumi-quickstart - Pulumi best practices
projen - Rapidly build modern applications with advanced configuration management
preview-environments - Quickly create temporary preview environments
awesome-projen - P6M7G8's Awesome Projen
knboard - Kanban boards with React & Django.
middy - 🛵 The stylish Node.js middleware engine for AWS Lambda 🛵
actions - A collection of GitHub Actions to run Pluralith in CI and automate infrastructure documentation generation
ctk - Visual composer for container based workloads
aws-sdk-js-v3 - Modularized AWS SDK for JavaScript.