1.0.5 • Published 6 years ago

serverless-assets-local v1.0.5

Weekly downloads
2
License
Apache-2.0
Repository
github
Last release
6 years ago

serverless-assets-local

serverless-assets-local は、assets ファイルなどを別サーバーで起動するような構成をシミュレーションすることが出来ます。 serverless-offline と共に利用してください。

view から参照する場合は、express-simple-cdn などでhostを置き換えられるようにするのがおすすめです。

Installation

npm install serverless-assets-local --save-dev

Example

serverless.yaml

service: serverless-assets-local-example
provider:
  name: aws
  runtime: nodejs6.10
plugins:
  - serverless-assets-local
  - serverless-offline
custom:
  assets:
    host: 127.0.0.1
    port: 8003
    directory: ./assets/
    originPath: /data
    cors: false
    # Uncomment only if you already have a Assets server running locally
    # noStart: true
functions:
  webhook:
    handler: handler.webhook
    events:
      - http:
          method: GET

See also

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago