Skip to content
This repository has been archived by the owner on Jun 15, 2024. It is now read-only.

Settings

Bruno Agutoli edited this page Apr 18, 2020 · 6 revisions

Minimal

Most simple way to setup that plugin with default functionality.

plugins:
  - serverless-layers

functions:
  hello:
    handler: handler.hello

With options

It's possible to specify options.

plugins:
  - serverless-layers

custom:
  serverless-layers:
    common:
      dependenciesPath: ./package.json

functions:
  hello:
    handler: handler.hello

Multiple Layers

There are two ways to specify your settings options:

A) Single layer

plugins:
  - serverless-layers

custom:
  serverless-layers:
    mySingleLayer:
      dependenciesPath: ./package.json

functions:
  hello:
    handler: handler.hello

B) List of layers

plugins:
  - serverless-layers

custom:
  serverless-layers:
    - myLayer1:
        dependenciesPath: ./path_foo/package.json
    - myLayer2:
        dependenciesPath: ./path_bar/package.json

functions:
  hello:
    handler: handler.hello
Clone this wiki locally