AWS Serverless Application Repository
Developer Guide

How to Publish Applications

This section provides you with procedures for publishing your serverless application to the AWS Serverless Application Repository by using the AWS SAM CLI or the AWS Management Console.

Important

The information that you enter when you publish an application isn't encrypted. This information includes data such as the author name. If you have personally identifiable information that you don't want to be stored or made public, we recommend that you don't enter this information when publishing your application.

Publishing an Application Through the AWS SAM CLI

The easiest way to publish and share an application to the AWS Serverless Application Repository is to use a set of AWS SAM CLI commands. For more information, see Publishing an Application Using the AWS SAM CLI in the AWS Serverless Application Model (AWS SAM) Developer Guide.

Publishing an Application Through the AWS Management Console

This section shows you how to use the AWS Management Console to publish an application to the AWS Serverless Application Repository.

Prerequisites

Before you publish an application to the AWS Serverless Application Repository, you need the following:

  • A valid AWS account.

  • A valid AWS Serverless Application Model (AWS SAM) template that defines the AWS resources that are used. For more information about AWS SAM templates, see AWS SAM Template Basics.

  • A package for your application that you created by using the AWS CloudFormation package command for the AWS CLI. This command packages the local artifacts (local paths) that your AWS SAM template references. For more details, see package in the AWS CloudFormation documentation.

  • A URL that points to your application's source code, in case you want to publish your application publicly.

  • A readme.txt file. This file should describe how customers can use your application, and how to configure it before deploying it in their own AWS accounts.

  • A license.txt file or a valid license identifier from the SPDX website. Note that a license is only required if you want to share your application publicly. If you're going to keep your application private or only share it privately, you don't need specify a license.

  • A valid Amazon S3 bucket policy that grants the service read permissions for artifacts that were uploaded to Amazon S3 when you packaged your application. To set this policy, follow these steps:

    1. Open the Amazon S3 console at https://console.aws.amazon.com/s3/.

    2. Choose the Amazon S3 bucket that you used to package your application.

    3. Choose the Permissions tab.

    4. Choose the Bucket Policy button.

    5. Paste the following policy statement into the Bucket policy editor. Make sure to substitute your bucket name in the Resource property value.

      { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "Service": "serverlessrepo.amazonaws.com" }, "Action": "s3:GetObject", "Resource": "arn:aws:s3:::bucketname/*" } ] }
    6. Choose the Save button.

Creating a New Application Through the AWS Management Console

Create a new application in the AWS Serverless Application Repository by using the following procedure.

To create a new application in the AWS Serverless Application Repository

  1. Open the AWS Serverless Application Repository console and choose Publish applications.

  2. On the Publish an application page, enter the indicated application information in the following boxes, and then choose Publish application:

    Property Required Description
    Application name TRUE

    The name of the application.

    Minimum length=1. Maximum length=140.

    Pattern: "[a-zA-Z0-9\\-]+";

    Author TRUE

    The name of the author publishing the application.

    Minimum length=1. Maximum length=127.

    Pattern: "^[a-z0-9](([a-z0-9]|-(?!-))*[a-z0-9])?$";

    Home page FALSE A URL with more information about the application—for example, the location of your GitHub repository for the application.
    Description TRUE

    The description of the application.

    Minimum length=1. Maximum length=256.

    Labels FALSE

    The labels that improve the discovery of applications in search results.

    Minimum length=1. Maximum length=127. Maximum number of labels: 10.

    Pattern: "^[a-zA-Z0-9+\\-_:\\/@]+$";

    Spdx license (drop-down list) FALSE Choose a valid license identifier from the drop-down that contains licenses that are available on the SPDX website. Choosing an item in the drop-down populates the License text box below it. Note: Choosing a license in the drop-down replaces the contents of the License text box, and discards any manual edits that you have made.
    License FALSE

    Upload a .txt license file, or choose a license from the Spdx license drop-down described in the previous row. Choosing a license from the Spdx license drop-down automatically populates the License text box. You can manually edit the contents of this text box after uploading a license file or choosing one from the Spdx license drop-down. However, if another Spdx license is chosen from the drop-down, any manual edits that you have made are discarded.

    This is an option field, but you must provide a license in order to share the application publicly.

    Readme FALSE

    Upload the contents of the Readme file, which can be in text or markdown format. These contents are displayed on the application's detail page in the AWS Serverless Application Repository. You can manually edit the contents of this text box after uploading a file.

    Semantic version FALSE

    The semantic version of the application. For more information, see the Semantic Versioning website.

    You must provide a value for this property in order to make your application public.

    Source code Url FALSE A link to a public repository for the source code of your application.
    SAM template TRUE

    A valid AWS Serverless Application Model (AWS SAM) template that defines the AWS resources that are used.

Sharing an Application Through the Console

Make your application publicly available by using the following procedure.

To make your application publicly available

  1. Open the AWS Serverless Application Repository console.

  2. On the navigation pane, choose My Applications to bring up the list of applications that you've created.

  3. Choose the application that you want to share.

  4. In the Application Details section, move the Visibility slider to Application is public.

Note

In order to share an application publicly, it must meet the following requirements: 1) It must be created in either us-east-1 or us-east-2, 2) It must have the SemanticVersion property set, and 3) It must have the LicenseUrl property set.

Publishing a New Version of an Existing Application Through the Console

Publish a new version of an application that you already created by using the following procedure.

To publish a new version of an application

  1. Open the AWS Serverless Application Repository console.

  2. On the navigation pane, choose My Applications to bring up the list of applications that you've created.

  3. Choose the application that you want to publish a new version for.

  4. Choose Publish new version.

  5. For AWS SAM template file, enter the name of the new AWS SAM template file for this version.

  6. Choose Publish.

Deleting an Application

You can delete applications from the AWS Serverless Application Repository by using either the AWS Management Console or the AWS SAM CLI.

Deleting an Application Through the AWS Management Console

To delete a published application through the AWS Management Console, do the following.

  1. Open the AWS Serverless Application Repository console.

  2. For My Applications, choose the application that you want to delete.

  3. In the application's detail page, choose Delete application.

  4. Choose Delete application to complete the deletion.

Deleting an Application Through the AWS CLI

To delete a published application using the AWS CLI, you run the aws serverlessrepo delete-application command. In the command, specify the application ID of the application that you want to delete.

The following command deletes an application, where <value> is the application ID:

PROMPT> aws serverlessrepo delete-application --application-id <value>