Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial commit of the AWS CDK Python Quickstarter #956

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

nichtraunzer
Copy link
Member

[Feature] Add Quickstarter for Python CDK (MVP)

Description:

This pull request introduces a new quickstarter called "Quickstarter for Python CDK". The Quickstarter for Python CDK simplifies the process of deploying cloud resources using the AWS Cloud Development Kit (CDK) for Python. It is supposed to be an addition to the existing inf-terraform-aws Quickstarter. CDK Python now offers a a familiar programming language, whereas Terraform is using a declarative language.
This is the first iteration of this long discussed and awaited component, and we're excited to share it with the community.

Key Features:

  • Streamlined setup process for AWS CDK Python projects using ODS.
  • Pre-configured template for common cloud resource deployments in AWS.

Dependencies:

  • The current implementation assumes that the AWS credentials are correctly configured in the environment (see inf-terraform-AWS also)

Since this PR is an MVP we're looking forward to receiving feedback and suggestions from the community to help improve the Quickstarter for Python CDK. Please feel free to review the changes and provide any comments or recommendations.

Open Topics:

  • Tagging: we need to make sure that deployed AWS resources are properly tagged. eg. using the CDK TagManager to tag a stack
  • Reports testing and content: Though we already create reports in the proper format, we need to have a common agreement what shall
  • Documentation

Contributors:

@nichtraunzer nichtraunzer changed the title Initial commit of the AWS CDK Python Quickstarter WIP Initial commit of the AWS CDK Python Quickstarter Sep 21, 2023
@nichtraunzer nichtraunzer changed the title WIP Initial commit of the AWS CDK Python Quickstarter Initial commit of the AWS CDK Python Quickstarter Oct 18, 2023
@@ -2,6 +2,8 @@

### Added

- inf-cdk-python-aws, provide first iteration of the AWS CDK Quickstarter ([#956](https://github.com/opendevstack/ods-quickstarters/pull/956))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just wondering about the naming:
There's also a terraform cdk - how would the name of that be
inf-terraform-cdk-python?

Based on that, this one should be
inf-aws-cdk-python :-D

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually someone else requested to remove "aws" because its evident ... but I am open to add that again :)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as mentioned, there's also terraform cdk so it's not evident, imho :-D

library("ods-jenkins-shared-library@${sharedLibraryRef}")

odsQuickstarterPipeline(
imageStreamTag: "${odsNamespace}/jenkins-agent-terraform2:${agentImageTag}",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this agent picked by design (just asking)?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since the agent already contains all required libs and tools - yes.
other ideas like a dedicated agent are welcome too ...

@@ -0,0 +1,5 @@
# CDK Python Quickstarter (inf-cdk-python-aws)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AWS CDK Python ...

@@ -0,0 +1,62 @@
# ODS AWS CDK Python Quickstarter
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here it is AWS CDK Python ....

If you want to develop locally, make sure those tools are available in your environment, too. To run your code locally execute the following commands:

```
$ python -mvenv .venv
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be aligned and use Makefile -> make init?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

interesting topic - originally i proposed that but some colleagues do not like a make target approach ...

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be aligned and use Makefile -> make init?

Personally I don't like the Makfile approach. It is hard to have that available on a local machine.

interesting topic - originally i proposed that but some colleagues do not like a make target approach ...

Guilty as charged!

$ cd src
$ source ../.venv/bin/activate && pip install -r requirements.txt -r requirements-dev.txt
```
You may want to to verify you code by running ...
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo:

You may want to verify your code by running:

```
$ export AWS_ACCESS_KEY_ID=...
$ export AWS_SECRET_ACCESS_KEY=...
$ export AWS_DEFAULT_REGION=us-east-1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd use eu-west-1 as the defaults above also direct to eu-west-1.

@@ -0,0 +1,7 @@
---
name: AWS CDK (Python)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here it is AWS CDK (Python)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jajajajaja ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants