From da5fb7cfc23757a0dcdd9b24eee19cced3701e02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Van=20der=20Auwermeulen=20Gr=C3=A9goire?= Date: Fri, 9 Jun 2017 10:09:07 +0200 Subject: [PATCH 1/2] Create README.md This is part off this change in serverless-webpack: elastic-coders/serverless-webpack#131 Explain how to work with the serverless-offline, serverless-webpack and serverless-dynamodb-local --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index 127976147..7eca52804 100644 --- a/README.md +++ b/README.md @@ -171,6 +171,18 @@ Options are: - `--function` or `-f` (required) is the name of the function to run - `--path` or `-p` (optional) is a JSON file path used as the function input event +### Using with serverless-offline and serverless-webpack plugin + + Run `serverless offline start`. In comparison with `serverless offline`, the `start` command will fire an `init` and a `end` lifecycle hook which is needed for serverless-offline and serverless-dynamodb-local to switch off both ressources. + + Add plugins to your `serverless.yml` file: + ```yaml + plugins: + - serverless-webpack + - serverless-dynamodb-local + - serverless-offline #serverless-offline needs to be last in the list + ``` + ### Bundle with webpack To just bundle and see the output result use: From 79db747333fd3a0d46bed4f4fb73522aa410fb99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Van=20der=20Auwermeulen=20Gr=C3=A9goire?= Date: Sat, 1 Jul 2017 21:24:14 +0200 Subject: [PATCH 2/2] Update README.md Fix typo --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7eca52804..ac0828561 100644 --- a/README.md +++ b/README.md @@ -173,7 +173,7 @@ Options are: ### Using with serverless-offline and serverless-webpack plugin - Run `serverless offline start`. In comparison with `serverless offline`, the `start` command will fire an `init` and a `end` lifecycle hook which is needed for serverless-offline and serverless-dynamodb-local to switch off both ressources. + Run `serverless offline start`. In comparison with `serverless offline`, the `start` command will fire an `init` and a `end` lifecycle hook which is needed for serverless-offline and serverless-dynamodb-local to switch off both resources. Add plugins to your `serverless.yml` file: ```yaml