Skip to content

Improve error messages for ssm permission issue #5781

Description

@gauntface

This is a Feature Proposal

Description

When setting environment variables with ${ssm:abcd} variables I was getting the following error message:

 Serverless Warning --------------------------------------

  A valid SSM parameter to satisfy the declaration 'ssm:abcd' could not be found.

When I try to access the variable with the AWS CLI, I get more information:

$ aws ssm get-parameter --name abcd                                                                255 ↵

An error occurred (AccessDeniedException) when calling the GetParameter operation: User: <user info> is not authorized to perform: abcd on resource: <param info>

After adding permissions to the serverless IAM policy, everything started to work as you'd expect.

Adding an error message, either a custom error regarding permissions OR passing through the AWS error would have been super helpful.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions