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

AWS Serverless Application Repository support #70

Open
jarreds opened this issue Jun 1, 2021 · 6 comments
Open

AWS Serverless Application Repository support #70

jarreds opened this issue Jun 1, 2021 · 6 comments

Comments

@jarreds
Copy link

jarreds commented Jun 1, 2021

The new AWS::CloudFormation::ResourceVersion & AWS::CloudFormation::ResourceDefaultVersion are currently not supported in AWS SAR.

Really bummed to have hit this. Is there any way you all could work w/ the SAR team to get these resource types put in the "allow" list?

Thanks!

@benkehoe
Copy link

benkehoe commented Jun 2, 2021

What functionality of SAR do you hope to use with a template with these resources in it? Would such a use case be solved by types in the CloudFormation registry being sharable between accounts?

@jarreds
Copy link
Author

jarreds commented Jun 2, 2021

We'd like to make a number of resources available for use by our customers, so they need to be public. The other mechanism we've considered for distributing the resource versions is via the marketplace.

Anyway, we feel that asking our customers to embed a simple SAR resource that handles all the resource registration stuff is much simpler UX. We're a serverless product too, so that just feels right as well.

  SaaSCloudFormationResources:
    Type: AWS::Serverless::Application
    Properties:
      Location:
        ApplicationId: arn:aws:serverlessrepo:us-east-1:#######:applications/######
        SemanticVersion: 1.0.0

@jarreds
Copy link
Author

jarreds commented Jun 2, 2021

Also, it seems we can get around this w/ custom resources in the SAR template, but who wants to write those.

@benkehoe
Copy link

benkehoe commented Jun 2, 2021

Would you distribute this via as a public SAR app or as a template/SAM project to be deployed by the customer?
If you would distribute via a public SAR app, would it work for you if it was possible to make your own public resource types, like the existing third-party ones like Datadog::Monitors::Monitor? https://aws.amazon.com/blogs/aws/cloudformation-update-cli-third-party-resource-support-registry/

@jarreds
Copy link
Author

jarreds commented Jun 2, 2021

We do have public resource types, very similar to DataDog. The SAR template in question is simply to install our third-party resource types into the customer account in an IaC pure way.

So rather than saying run a CLI action like this to register our types:

aws cloudformation register-type \
    --region "<REGION>" \
    --type RESOURCE \
    --type-name "<DATADOG_RESOURCE_NAME>" \
    --schema-handler-package "<LINK_TO_S3>"

Just put this into CloudFormation, and you'll get the same net effect but via IaC:

  SaaSCloudFormationResources:
    Type: AWS::Serverless::Application
    Properties:
      Location:
        ApplicationId: arn:aws:serverlessrepo:us-east-1:#######:applications/######
        SemanticVersion: 1.0.0

@jarreds
Copy link
Author

jarreds commented Jun 2, 2021

It also gives us better semantic versioning and whatnot.

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

No branches or pull requests

2 participants