Giter VIP home page Giter VIP logo

cdk-eks-blueprints-patterns's Introduction

EKS Blueprints Patterns

Welcome to the EKS Blueprints Patterns repository.

This repository contains a number of samples for how you can leverage the Amazon EKS Blueprints. You can think of the patterns as "codified" reference architectures, which can be explained and executed as code in the customer environment.

Patterns

The individual patterns can be found in the lib directory. Most of the patterns are self-explanatory, for some more complex examples please use this guide and docs/patterns directory for more information.

Documentation

Please refer to the Amazon EKS Blueprints Patterns documentation site for complete list of Amazon EKS Blueprints patterns documentation.

Please refer to the Amazon EKS Blueprints Quick Start documentation site for complete project documentation.

Usage

Before proceeding, make sure AWS CLI is installed on your machine.

To use the eks-blueprints and patterns module, you must have Node.js and npm installed. You will also use make and brew to simplify build and other common actions.

RHEL Setup

Follow the below steps to setup and leverage eks-blueprints and eks-blueprints-patterns in your Amazon Linux/CentOS/RHEL Linux machine.

  1. Update the package list

    Update the package list to ensure you're installing the latest versions.

    sudo yum update
  2. Install make

    sudo yum install make
  3. Install brew by following instructions as detailed in docs.brew.sh

     /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

    Add Homebrew to your PATH

    test -d ~/.linuxbrew && eval "$(~/.linuxbrew/bin/brew shellenv)"
    test -d /home/linuxbrew/.linuxbrew && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
    test -r ~/.bash_profile && echo "eval \"\$($(brew --prefix)/bin/brew shellenv)\"" >> ~/.bash_profile
    echo "eval \"\$($(brew --prefix)/bin/brew shellenv)\"" >> ~/.profile

    Verify brew installation

    brew -v
  4. Install Node.js and npm

    Install Node.js v18 and npm using brew.
    
    ```bash
    brew install node@18
    ```
    
    Note: Node.js package includes npm
    
    Set PATH for node@18
    
    ```bash
    test -r ~/.bash_profile && echo 'export PATH="/home/linuxbrew/.linuxbrew/opt/node@18/bin:$PATH"' >> ~/.bash_profile
    echo 'export PATH="/home/linuxbrew/.linuxbrew/opt/node@18/bin:$PATH"' >> ~/.profile
    export PATH="/home/linuxbrew/.linuxbrew/opt/node@18/bin:$PATH"
    ```
    

    Post completing the above, continue from Verify Node.js and npm Installation

Ubuntu Setup

Follow the below steps to setup and leverage eks-blueprints and eks-blueprints-patterns in your Ubuntu Linux machine.

  1. Update the package list

    Update the package list to ensure you're installing the latest versions.

    sudo apt update
  2. Install make

    sudo apt install make
  3. Install brew by following instructions as detailed in docs.brew.sh

     /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

    Add Homebrew to your PATH

    test -d ~/.linuxbrew && eval "$(~/.linuxbrew/bin/brew shellenv)"
    test -d /home/linuxbrew/.linuxbrew && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
    test -r ~/.bash_profile && echo "eval \"\$($(brew --prefix)/bin/brew shellenv)\"" >> ~/.bash_profile
    echo "eval \"\$($(brew --prefix)/bin/brew shellenv)\"" >> ~/.profile

    Verify brew installation

    brew -v
  4. Install Node.js and npm

    Install Node.js v18 and npm using brew.

    brew install node@18

    Note: Node.js package includes npm

    Set PATH for node@18

    test -r ~/.bash_profile && echo 'export PATH="/home/linuxbrew/.linuxbrew/opt/node@18/bin:$PATH"' >> ~/.bash_profile
    echo 'export PATH="/home/linuxbrew/.linuxbrew/opt/node@18/bin:$PATH"' >> ~/.profile
    export PATH="/home/linuxbrew/.linuxbrew/opt/node@18/bin:$PATH"

Post completing the above, continue from Verify Node.js and npm Installation

Mac Setup

Follow the below steps to setup and leverage eks-blueprints and eks-blueprints-patterns in your local Mac laptop.

  1. Install make, node and npm using brew

    brew install make
    brew install node@18

    Note: Node.js package includes npm

    Set PATH for node@18

    echo 'export PATH="/opt/homebrew/opt/node@18/bin:$PATH"' >> ~/.zshrc
    export PATH="/opt/homebrew/opt/node@18/bin:$PATH"

Verify Node.js and npm Installation

  1. Check the installed version of Node.js

    node -v

    The output should be v18.x.x.

  2. Check the installed version of npm

    npm -v

    The output should be a version greater than 9.x.x.

    If your npm version is not 9.x.x or above, update npm with the following command:

    sudo npm install -g npm@latest

    Verify the installed version by running npm -v.

Repo setup

  1. Clone cdk-eks-blueprints-patterns repository

    git clone https://github.com/aws-samples/cdk-eks-blueprints-patterns.git
    cd cdk-eks-blueprints-patterns

    PS: If you are contributing to this repo, please make sure to fork the repo, add your changes and create a PR against it.

  2. Once you have cloned the repo, you can open it using your favourite IDE and run the below commands to install the dependencies and build the existing patterns.

  • Install project dependencies.

    make deps
  • To view patterns that are available to be deployed, execute the following:

    npm i
    make build
  • To list the existing CDK EKS Blueprints patterns

    make list

Note: Some patterns have a hard dependency on AWS Secrets (for example GitHub access tokens). Initially you will see errors complaining about lack of the required secrets. It is normal. At the bottom, it will show the list of patterns which can be deployed, in case the pattern you are looking for is not available, it is due to the hard dependency which can be fixed by following the docs specific to those patterns.

To work with patterns use:
        $ make pattern <pattern-name> <list | deploy | synth | destroy>
Example:
        $ make pattern fargate deploy

Patterns:

        bottlerocket
        data-at-rest
        datadog
        dynatrace-operator
        ecr-image-scanning
        emr
        fargate
        generative-ai-showcase
        generic-cluster-provider
        guardduty
        jupyterhub
        kasten
        keptn-control-plane
        konveyor
        kubecost
        kubeflow
        multi-region
        multi-team
        newrelic
        nginx
        pipeline-multienv-gitops
        pipeline-multienv-monitoring
        pipeline
        rafay
        secure-ingress-cognito
        snyk
        starter
        gmaestro
        workloads-codecommit
  • Bootstrap your CDK environment.

    npx cdk bootstrap
  • You can then deploy a specific pattern with the following:

    make pattern multi-team deploy

Developer Flow

Modifications

All files are compiled to the dist folder including lib and bin directories. For iterative development (e.g. if you make a change to any of the patterns) make sure to run compile:

make compile

The compile command is optimized to build only modified files and is fast.

New Patterns

To create a new pattern, please follow these steps:

  1. Under lib create a folder for your pattern, such as <pattern-name>-construct. If you plan to create a set of patterns that represent a particular subdomain, e.g. security or hardening, please create an issue to discuss it first. If approved, you will be able to create a folder with your subdomain name and group your pattern constructs under it.
  2. Blueprints generally don't require a specific class, however we use a convention of wrapping each pattern in a plain class like <Pattern-Name>Construct. This class is generally placed in index.ts under your pattern folder.
  3. Once the pattern implementation is ready, you need to include it in the list of the patterns by creating a file bin/<pattern-name>.ts. The implementation of this file is very light, and it is done to allow patterns to run independently.

Example simple synchronous pattern:

import { configureApp } from "../lib/common/construct-utils";
import FargateConstruct from "../lib/fargate-construct";

new FargateConstruct(configureApp(), "fargate"); // configureApp() will create app and configure loggers and perform other prep steps
  1. In some cases, patterns need to use async APIs. For example, they may rely on external secrets that you want to validate ahead of the pattern deployment.

Example async pattern:

import { configureApp, errorHandler } from "../lib/common/construct-utils";

const app = configureApp();

new NginxIngressConstruct().buildAsync(app, "nginx").catch((e) => {
  errorHandler(
    app,
    "NGINX Ingress pattern is not setup. This maybe due to missing secrets for ArgoCD admin pwd.",
    e
  );
});
  1. There are a few utility functions that can be used in the pattern implementation such as secret prevalidation. This function will fail if the corresponding secret is not defined, this preventing the pattern to deploy.
await prevalidateSecrets(
  NginxIngressConstruct.name,
  undefined,
  SECRET_ARGO_ADMIN_PWD
);
await prevalidateSecrets("my-pattern-name", "us-east-1", "my-secret-name"); //

Contributing

See Contributing guide for requirements on contribution.

Deploying Blueprints with External Dependency on AWS Resources

There are cases when the blueprints defined in the patterns have dependencies on existing AWS Resources such as Secrets defined in the account/region. For such cases, you may see errors if such resources are not defined.

For PipelineMultiEnvGitops please see instructions in this README.

For MultiRegionConstruct the pattern relies on the following secrets defined:

  1. github-ssh-key - must contain GitHub SSH private key as a JSON structure containing fields sshPrivateKey and url. The secret is expected to be defined in us-east-1 and replicated to us-east-2 and us-west-2 regions. For more information on SSH credentials setup see ArgoCD Secrets Support. Example Structure:
{
    "sshPrivateKey": "-----BEGIN THIS IS NOT A REAL PRIVATE KEY-----\nb3BlbnNzaC1rtdjEAAAAABG5vbmUAAAAEbm9uZQAAAAAAAAABAAACFwAAAAdzc2gtcn\nNhAAAAAwEAAQAAAgEAy82zTTDStK+s0dnaYzE7vLSAcwsiHM8gN\nhq2p5TfcjCcYUWetyu6e/xx5Rh+AwbVvDV5h9QyMw4NJobwuj5PBnhkc3QfwJAO5wOnl7R\nGbehIleWWZLs9qq`DufViQsa0fDwP6JCrqD14aIozg6sJ0Oqi7vQkV+jR0ht/\nuFO1ANXBn2ih0ZpXeHSbPDLeZQjlOBrbGytnCbdvLtfGEsV0WO2oIieWVXJj/zzpKuMmrr\nebPsfwr36nLprOQV6IhDDo\n-----END NOT A REAL PRIVATE KEY-----\n",

    "url": "git@github"
}

Note: You can notice explicit \n characters in the sshPrivateKey.

  1. argo-admin-secret - must contain ArgoCD admin password in Plain Text. The secret is expected to be defined in us-east-1 and replicated to us-east-1 and us-west-2 regions.

For ``Dynatrace One Agent`

  • dynatrace-tokens - must contain API_URL, API_TOKEN and PAAS_TOKEN in Plain Text. The secret is expected to be defined in the target region (either directly or through AWS Secrets Manager Replication).

For keptn-control-plane the pattern relies on the following secrets defined:

  • keptn-secrets - must contain API_TOKEN and BRIDGE_PASSWORD password in Plain Text. The secret is expected to be defined in us-east-1 region.

For newrelic the pattern relies on the following secrets defined:

  • newrelic-pixie-keys - must contain New Relic (required) and Pixie keys (optional). The secret is expected to be defined in the target region (either directly or through AWS Secrets Manager Replication).

For more information on defining secrets for ArgoCD, please refer to Blueprints Documentation as well as known issues.

For nginx please see NGINX Blueprint documentation.

For datadog the pattern relies on the following secret defined:

  • apiKeyAWSSecret - must contain the Datadog API key in Plain Text named datadog-api-key. The secret is expected to be defined in the target region.

For kubeflow please see Kubeflow documentation.

For secure-ingress-cognito please see Secure Ingress using Cognito Blueprint documentation.

For GmaestroConstruct the pattern relies on the following secret defined:

  • granulate-client-id - must contain the client_id Plain Text. The secret is expected to be defined in the target region (either directly or through AWS Secrets Manager Replication).

Security

See CONTRIBUTING for more information.

License

This library is licensed under the MIT-0 License. See the LICENSE file.

cdk-eks-blueprints-patterns's People

Contributors

ajpaws avatar aliaksei-ivanou avatar amazon-auto avatar arpitn2020 avatar bpschmitt avatar celenechang avatar elamaran11 avatar elenalape avatar freschri avatar heckelmann avatar howlla avatar htreu avatar iamprakkie avatar jumic avatar kcaws avatar kutumba-rafay avatar lmouhib avatar niravparikh05 avatar parkand1 avatar ratnopamc avatar realvz avatar ronahk avatar rounoff avatar sbollers avatar schottsfired avatar shapirov103 avatar tsahiduek avatar victorgu-github avatar youngjeong46 avatar zjaco13 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cdk-eks-blueprints-patterns's Issues

How to pass existing VPC in pipeline stack using ParameterStore

Is your feature request related to a problem? Please describe.
When defining the pipeline stack by following the guide https://github.com/aws-samples/cdk-eks-blueprints-patterns/blob/main/lib/pipeline-multi-env-gitops/index.ts, I want to provide my existing VPC configuration. I have stored my VPC detail in the target account parameter store which I want to fetch and pass to the blueprint.

Describe the solution you'd like

I want to pass resource provider as

   const vpcProvider = new blueprints.VpcProvider(ssm.StringParameter.valueFromLookup(scope, '/devops/network/workspace/vpc/id'))
        const blueprint = blueprints.EksBlueprint.builder()
          .version(clusterVersion)
          .resourceProvider(blueprints.GlobalResources.Vpc, vpcProvider)
          .clusterProvider(
            // blueMNG,
            greenMNG,
          )

This compiles fine, however this give an error

2023-01-14 01:57:08.098  ERROR [main bin/main.ts:70 undefined.<anonymous>] 
 Error  App at '' should be created in the scope of a Stack, but no Stack found
error stack:
• stack.js:1 _lookup
    node_modules/aws-cdk-lib/core/lib/stack.js:1:4048

• stack.js:1 of
    node_modules/aws-cdk-lib/core/lib/stack.js:1:3783

• context-provider.js:2 getValue
    node_modules/aws-cdk-lib/core/lib/context-provider.js:2:451

• parameter.js:1 valueFromLookup
    node_modules/aws-cdk-lib/aws-ssm/lib/parameter.js:1:6365

• index.ts:109 buildAsync
    lib/pipeline-multi-env-gitops/index.ts:109:76

• task_queues:95 processTicksAndRejections
    node:internal/process/task_queues:95:5

Wondering what is the right way to handle this?

Documentation for Backstage addon points to a pattern, but no pattern exists

Is your feature request related to a problem? Please describe.
Pattern for backstage addon as requested here

Describe the solution you'd like
A pattern implementing all of the necessary resource providers for backstage to deploy successfully

Describe alternatives you've considered
Also could add more information on the actual docs page in the cdk-eks-blueprints repo

Error in CodePipeline when installing pipeline-multienv-gitops pattern -- No stacks match the name(s) eks-blueprint-pipeline-stack

Describe the bug

I am trying to install the Pipeline multi environment pattern using the instructions provided. I get a CodePipeline error in the UpdatePipeline stage after I run the following command:

make pattern pipeline-multienv-gitops deploy eks-blueprint-pipeline-stack

The error I get is 'No stacks match the name eks-blueprint-pipeline-stack' even though the stack is available in the same account and in the same region. Here is a snippet of the build logs:

--
111 | No stacks match the name(s) eks-blueprint-pipeline-stack
112 | [22:22:14] Error: No stacks match the name(s) eks-blueprint-pipeline-stack
113 | at CdkToolkit.validateStacksSelected (/usr/local/lib/node_modules/aws-cdk/lib/index.js:402:3959)
114 | at CdkToolkit.selectStacksForDeploy (/usr/local/lib/node_modules/aws-cdk/lib/index.js:402:2861)
115 | at async CdkToolkit.deploy (/usr/local/lib/node_modules/aws-cdk/lib/index.js:400:146574)
116 | at async exec4 (/usr/local/lib/node_modules/aws-cdk/lib/index.js:455:51970)
117 |  
118 | [Container] 2023/06/06 22:22:14 Command did not exit successfully cdk -a . deploy eks-blueprint-pipeline-stack --require-approval=never --verbose exit status 1
119 | [Container] 2023/06/06 22:22:14 Phase complete: BUILD State: FAILED
120 | [Container] 2023/06/06 22:22:14 Phase context status code: COMMAND_EXECUTION_ERROR Message: Error while executing command: cdk -a . deploy eks-blueprint-pipeline-stack --require-approval=never --verbose. Reason: exit status 1

To Reproduce
Follow instructions in README

Expected behavior
CloudFormation and CodePipeline stages complete successfully

** Versions **

  • node v20.2.0
  • npm v9.6.6
  • cdk v2.02.0

Multi Cluster Pattern for EKS Addon Validation for Conformitron

Is your feature request related to a problem? Please describe.
Multi Cluster Pattern for EKS Addon Validation for Conformitron

Describe the solution you'd like
Multi Cluster Pattern for EKS Addon Validation for Conformitron

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

New EKS Blueprints Pattern for AMP Addon.

Is your feature request related to a problem? Please describe.
This is not related to a problem. A New EKS Blueprints Pattern for AMP Add-on would benefit the users on coverage for different cases when user defined AMP workspace is used for AMP Adot Add-on.

Describe the solution you'd like
We should be adding a new EKS blueprints AMP addon which covers different usecases when AMP Workspace URL is passed to AMP addon.

Kubernetes Multi-Cluster Service Discovery using Open Source AWS Cloud Map MCS Controller Pattern

Is your feature request related to a problem? Please describe.
A pattern for Kubernetes Multi-Cluster Service Discovery using Open Source AWS Cloud Map MCS Controller with EKS Blueprints

Describe the solution you'd like
Based on https://aws.amazon.com/blogs/opensource/kubernetes-multi-cluster-service-discovery-using-open-source-aws-cloud-map-mcs-controller/

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

E2E test shows errors for Multi Region Construct

Describe the bug
Even with the two secrets added on the account (github-ssh-key and argo-admin-secret), cdk list does not pass due to dependency issues.

To Reproduce
Steps to reproduce the behavior:

  1. Create the two secrets listed above in Secrets Manager. For the purpose of this testing, I used arbitrary plaintexts.
  2. Clone and cd into the repo.
  3. Run make bootstrap to install necessary packages.
  4. Boostrap environment using cdk bootstrap
  5. execute cdk list

Expected behavior
List all of the blueprints available.

Screenshots
The following error occurred:

Assertion failed: Missing a dependency for AwsLoadBalancerControllerAddOn for multi-region-us-east-1
Assertion failed: Missing a dependency for AwsLoadBalancerControllerAddOn for multi-region-us-east-2
Assertion failed: Missing a dependency for AwsLoadBalancerControllerAddOn for multi-region-us-west-2

/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/constructs/src/private/dependency.ts:84
    const ret = (instance as any)[DEPENDABLE_SYMBOL];
                                 ^
TypeError: Cannot read property 'Symbol(@aws-cdk/core.DependableTrait)' of undefined
    at Function.get (/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/constructs/src/private/dependency.ts:84:34)
    at Node.get dependencies [as dependencies] (/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/constructs/src/construct.ts:247:46)
    at ConstructNode.get dependencies [as dependencies] (/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/@aws-cdk/core/lib/construct-compat.ts:293:69)
    at Object.prepareApp (/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/@aws-cdk/core/lib/private/prepare-app.ts:20:38)
    at Object.synthesize (/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/@aws-cdk/core/lib/private/synthesis.ts:24:3)
    at App.synth (/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/@aws-cdk/core/lib/stage.ts:94:23)
    at process.<anonymous> (/Users/yojeo/src/patterns/ssp-eks-patterns/node_modules/@aws-cdk/core/lib/app.ts:64:45)
    at Object.onceWrapper (events.js:422:26)
    at process.emit (events.js:315:20)
    at process.EventEmitter.emit (domain.js:486:12)

Desktop (please complete the following information):

  • OS: MacOS
  • npm v8.1
  • node v14.15.1
  • aws cdk v.1.124.0

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Curiously enough, when I comment out the Multi Region Blueprint from bin/main.ts, and run cdk list again, the following output happens:

cross-region-stack-661554271967:us-east-2
cross-region-stack-661554271967:us-west-1
bottlerocket-blueprint
custom-cluster-blueprint
fargate-blueprint
multi-team-blueprint
nginx-blueprint
scratchpad-blueprint
ssp-pipeline-stack
ssp-pipeline-stack/us-east-2-managed-ssp/us-east-2-managed-ssp-blueprint
ssp-pipeline-stack/us-west-1-managed-ssp/us-west-1-managed-ssp-blueprint

In addition to listing all the blueprints, it also lists the cross region stacks for two of the 3 regions expected from the Multi Region Blueprint (even though it is commented out).

Documentation Site for EKS CDK Blueprints Patterns.

Is your feature request related to a problem? Please describe.
Documentation Site for EKS CDK Blueprints Patterns.

Describe the solution you'd like
Documentation Site for EKS CDK Blueprints Patterns. We might need mkdocs in blueprints patterns site as a GTM for our patterns.

Describe alternatives you've considered
Mkdocs in blueprints cdk repo is aligned to that repo for addons.

Additional context
Add any other context or screenshots about the feature request here.

VPC Lattice Pattern

Is your feature request related to a problem? Please describe.
Amazon VPC Lattice being generally available, with Amazon EKS, it would be good to have a pattern to leverage Amazon VPC Lattice through the use of the AWS Gateway API Controller, an implementation of the Kubernetes Gateway API.

Describe the solution you'd like
VPC Lattice Pattern could provide following, but not limited to:

  • Service Directory
  • Networks
  • Resource and Auth Policies
  • Gateways
  • Kubernetes multi-cluster connectivity: Pattern where VPC Lattice handles connectivity between clusters without needing sidecars

Additional context
AWS Gateway API Controller User Guide

Support for Amazon GuardDuty as a deployment pattern/construct

Is your feature request related to a problem? Please describe.
The ability to leverage Amazon GuardDuty to continuously monitor and profile Amazon EKS cluster activity to identify malicious or suspicious behavior to underlying container workloads

Describe the solution you'd like
To have Amazon GuardDuty as a EKS Blueprints deployment pattern to address potential security findings that includes container details such as pod ID, container image ID, and associated tags.

Describe alternatives you've considered
There are open-source products that address continuous monitoring but would like to use Amazon native services.

Additional context
Ideally by leveraging such pattern, the pattern will enable GuardDuty in the various AWS accounts being operated in along with automating the ability for sending notifications via email based on threats found in Guard Duty

JupyterHub Pattern

Is your feature request related to a problem? Please describe.
With JupyterHub addon being created, it will be good to create a pattern around it.

Describe the solution you'd like
JupyterHub pattern will consist of the following:

  • Authentication model (using Cognito)
  • EBS as persistent storage (using EBS CSI Driver Addon) (possibly also EFS)
  • Load Balancing with Load Balancer controller Addon
  • Certificates for HTTPS connection
  • R53 for DNS resolution

IPv6 Pattern

Is your feature request related to a problem? Please describe.
We would need a EKS CDK Blueprints pattern to demonstrate IPV6 on EKS and solves Ipv6 setup out of the box.

Describe the solution you'd like
We would need a EKS CDK Blueprints pattern to demonstrate IPV6 on EKS which automates out of the box to setup Ipv6 which is manually done in this blog - https://aws.amazon.com/blogs/containers/amazon-eks-launches-ipv6-support/

Describe alternatives you've considered
We would need a EKS CDK Blueprints pattern to demonstrate IPV6 on EKS

Additional context
Add any other context or screenshots about the feature request here.

Backstage pattern failed to create due to namespaces "backstage" not found

Describe the bug
A clear and concise description of what the bug is.
Failed to deploy the backstage pattern because of below error:

11:57:34 AM | CREATE_FAILED        | Custom::AWSCDK-EKS-KubernetesResource       | BackstageDatabaseExternalSecretA3EDF340
Received response status [FAILED] from custom resource. Message returned: Error: b'Error from server (NotFound): error when creating "/tmp/manifest.yaml": namespaces "backstage" not found\n'

Logs: /aws/lambda/backstage-blueprint-awscdkawseksKu-Handler886CB40B-gygkSKUeNmUY

at invokeUserFunction (/var/task/framework.js:2:6)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async onEvent (/var/task/framework.js:1:369)
at async Runtime.handler (/var/task/cfn-response.js:1:1676) (RequestId: 2d37c026-f026-42c9-9b16-066c8c9dbc5c)

From Lambda logs, it happened when it was deploying externalsecret.

{
    "RequestType": "Create",
    "ServiceToken": "arn:aws:lambda:ap-northeast-1:625011733915:function:backstage-blueprint-awscd-ProviderframeworkonEvent-6WbM98hbI8IV",
    "ResponseURL": "...",
    "StackId": "arn:aws:cloudformation:ap-northeast-1:625011733915:stack/backstage-blueprint/76269280-f8c1-11ee-b8fb-0a87d7790c8b",
    "RequestId": "2d37c026-f026-42c9-9b16-066c8c9dbc5c",
    "LogicalResourceId": "BackstageDatabaseExternalSecretA3EDF340",
    "ResourceType": "Custom::AWSCDK-EKS-KubernetesResource",
    "ResourceProperties": {
        "ServiceToken": "arn:aws:lambda:ap-northeast-1:625011733915:function:backstage-blueprint-awscd-ProviderframeworkonEvent-6WbM98hbI8IV",
        "PruneLabel": "aws.cdk.eks/prune-c8f0cf7145093742876bbb2d2485f38bdfd79948ba",
        "ClusterName": "backstage-blueprint",
        "Manifest": "[{\"apiVersion\":\"external-secrets.io/v1beta1\",\"kind\":\"ExternalSecret\",\"metadata\":{\"name\":\"external-backstage-db-secret\",\"namespace\":\"backstage\",\"labels\":{\"aws.cdk.eks/prune-c8f0cf7145093742876bbb2d2485f38bdfd79948ba\":\"\"}},\"spec\":{\"secretStoreRef\":{\"name\":\"secret-manager-store\",\"kind\":\"ClusterSecretStore\"},\"target\":{\"name\":\"backstage-database-secret\"},\"data\":[{\"secretKey\":\"POSTGRES_PASSWORD\",\"remoteRef\":{\"key\":\"databasesecret6A44CD8F-XOT9G17LNmay\",\"property\":\"password\"}},{\"secretKey\":\"POSTGRES_USER\",\"remoteRef\":{\"key\":\"databasesecret6A44CD8F-XOT9G17LNmay\",\"property\":\"username\"}}]}}]",
        "RoleArn": "arn:aws:iam::625011733915:role/backstage-blueprint-backstageblueprintCreationRoleE-F0mX1Y5aiwQr"
    }
}

To Reproduce
Steps to reproduce the behavior:
Deploy the backstage pattern.

$ make deps 
$ npm i
$ make build
$ make pattern backstage deploy

Expected behavior
A clear and concise description of what you expected to happen.
The backstage environment can be created successfully.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):
Cloud9 with Amazon Linux 2023

Smartphone (please complete the following information):
NA

Additional context
Add any other context about the problem here.

Show vulnerable ECR images in use

Is your feature request related to a problem? Please describe.
Images stored in ECR are scanned with Inspector2 for security vulnerabilities. When new vulnerabilities are detected in images, I would like to know which of the affected images are currently in use in any of the deployed EKS clusters. This will help evaluate the attack surface and prioritize the efforts for remediating the security threats.

Describe the solution you'd like
As a part of the security pattern configuring container image vulnerability scanning with Amazon inspector, we can create an EventBridge event that will be triggered every time a new EKS cluster is created. The event will asynchronously invoke an Orchestrator Lambda that will create an Image-Verifier Lambda function specific to a particular EKS cluster. The Image-Verifier Lambda function will be invoked every time a new vulnerability is detected by Inspector2 and will check if any of the affected images are currently in use in a specific EKS cluster. In case the image is in use, the Image-Verifier Lambda will use SNS to notify interested parties.

Describe alternatives you've considered
We can utilize partner solutions as an alternative.

Additional context
Add any other context or screenshots about the feature request here.

Karpenter patterns with Spot

Is your feature request related to a problem? Please describe.
Karpenter Addon could have a pattern where Spot instance is utilized.

Describe the solution you'd like
Create a new pattern or revise the current Karpenter pattern to illustrate how to use with Spot

Additional context
It will need to check for a prerequisite - EC2 Spot Service Linked Role

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.