Enterprise-CMCS / macpro-quickstart-serverless

Other
18 stars 14 forks source link

Use `serverless-offline-ssm` plugin #574

Closed ben-harvey closed 1 year ago

ben-harvey commented 2 years ago

Purpose

This change adds the serverless-offline-ssm plugin so that running the Quickstart locally does not require AWS credentials.

Linked Issues to Close

Approach

The QuickStart already supports local development via the serverless-offline and serverless-local-s3 plugins and the dev.ts script. However, when running locally, the uploads and app-api services can't start because of a dependency on SSM parameters.

This change adds the serverless-offline-ssm plugin to remove this dependency. The plugin is configured to only take effect for the local stage, and provides default values for the SSM variables for the uploads and app-api services directly, rather than reading them from AWS.

Learning

Assorted Notes/Considerations

Testing: I ran dev.ts local and confirmed that all services started without error, even without AWS credentials in the local environment.

Pull Request Creator Checklist

Pull Request Reviewer/Assignee Checklist