[sam] SAR Applications from CDK
- Dominant language
- TypeScript
- Stars
- 12.9k
- Forks
- 4.6k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 83
Description
## :rocket: Feature Request
### General Information
* [X] :wave: I may be able to implement this feature request
* [ ] :warning: This feature might incur a breaking change
### Description
The aws-delivlib has some pretty well built abstractions in place for building a CI/CD pipeline. I'd like to be able to re-use that for building/testing/publishing my Lambda Layers. The current support for Semantic Versioning in Layers is a bit rough and some people have started publishing their layers as SAR Applications which solves a few problems. First, a published SAR App is immediately available in every region (while a Layer Version has to be explicitly deployed to every region where you want it offered). Second, a SAR App creates a local copy of the Layer in the account that consumes the App. This isolates the client from disruptions caused by a layer being unpublished by a provider, which means customers will have greater trust in the Public SAR App and Lambda Layer ecosystem.
### Proposed Solution
* SAR Application Construct that takes a Path to a local build artifact and uploads it to S3 (most likely in a separate folder from the rest of the CDK artifacts and grants SAR scoped read permission on that directory)
* aws-delivlib publishToSAR() method that performs the actual `sam publish` in the pipeline after the artifact has been built and tested.
This feels like it's going to be REALLY hard to do, but it'll also add a lot of SAM coverage to CDK.
### Environment
All of them?
### Other information
https://serverless.pub/sar-layers/
Contributor guide
Research direction
Start by reviewing the existing aws-delivlib pipeline abstractions and how CDK artifacts are uploaded and published. Define the SAR Application construct and publishToSAR() flow around the proposed local artifact, S3 permissions, and sam publish step; done means the artifact can be built, tested, uploaded, and published as a SAR application.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws
- Domain
- cloud, devops
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100