Now let's create a simple service through the serverless Node.js template by going through the following steps:
- Create a new serverless service/project:
$ serverless create --template openwhisk-nodejs --path new-service
- Change into the newly created directory:
$ cd new-service
- Install the npm dependencies:
$ npm install
- Once we finished, deploy the service and function to the Bluemix portal:
$ serverless deploy -v
- Then we invoke the function to check whether the function is deployed properly. Invoke the serverless application using the following code:
$ serverless invoke --function hello { "payload": "Hello, World!" }
In the preceding tutorial, we got the auth keys, created an action, and deployed ...