serverless-disable-functions

1.0.0 • Public • Published

serverless-disable-functions

A simple serverless plugin to disable functions.

Install

yarn add --dev serverless-disable-functions

or

npm install --save-dev serverless-disable-functions

Add the plugin to your serverless.yml file:

plugins:
  - serverless-disable-functions

Usage

Add the parameter enabled: false to a function to disable it. This allows you to enable/disable functions by stage like so:

service: hello-service
provider: aws
custom:
  hello_enabled:
    dev: true
    prod: false

functions:
  hello:
    handler: handler.hello
    enabled: ${self:custom.hello_enabled.${opt:stage}}

Dependents (0)

Package Sidebar

Install

npm i serverless-disable-functions

Weekly Downloads

10,664

Version

1.0.0

License

GPL-3.0-or-later

Unpacked Size

41.8 kB

Total Files

20

Last publish

Collaborators

  • abemedia