Skip to main content

Native support for cdk and sam

Currently, we have to create our own custom image to include AWS SAM or any CDK.

It would be nice to include them while we setup a stack with the Cloudformation vendor.

Workaround
Create a custom image.
Status: 🔭 Discovery2 comments

Log in to comment and vote

Comments2

  • Black Breeze

    •

    May 8, 2025

    Hey — appreciate the feedback.

    You’re totally right: compared to Terraform/OpenTofu, tools like CDK and SAM introduce runtime and language-level complexity (Python, JS, compilers, etc.), which makes generic support difficult. It’s not just installing a CLI—it’s also managing version drift, compilers, and dependency resolution. So we haven’t bundled these by default.

    That said, we want to understand how you would prefer to use them:

    • What would “native support” mean to you? Is it having the CLI preinstalled, or full environment support (like npm, pip, etc.)?

    • How often do you change versions or languages in your CDK/SAM stacks?

    • Would it help to have official example images, or Spacelift-maintained base images you can extend?

    • Would adding them via Context hooks be sufficient—or is that too brittle?

    We’d love to make this feel less painful without trying to build a one-size-fits-none solution.

    • Azure Breeze

      •

      May 9, 2025

      Hello !

      I agree, about CDK it’s probably not so easy to implement because of the various languages supported. Having a base image to extend IMO won’t reduce the pain, as we would have to manage our own Docker image, and keep it up to date.
      I like the idea to have pre-built context that will ease the installation of such tools. Obviously, it should be fast enough.

      About SAM, I have the feeling you can add it directly within your image and make sure that Docker in Docker is fine. SAM can use docker container to build the assets, so you haven’t to install the dependency directly into the host.