lpinca / serverless-plugin-sns

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Serverless Plugin SNS

This plugin easily subscribes your lambda functions to SNS notifications.

Note: This plugin supports Serverless 0.2.*

Installation

cd projectfolder
npm install serverless-plugin-sns
  • add the plugin to your s-project.json file
"plugins": [
    "serverless-plugin-sns"
]

Run the Plugin

  • the plugin uses a hook that is called after each deployment of a function
  • you only have to deploy your function as usual sls function deploy
  • add the following attribute to the s-function.json in your functions folder
  ...
  "sns": {
    "topic": "your-dev-sns-topic"
  },
  ...
  • the topic will be created automatically, if not yet done

Next Steps

About


Languages

Language:JavaScript 100.0%