You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openwhisk.apache.org by GitBox <gi...@apache.org> on 2018/02/08 01:40:34 UTC

[GitHub] pritidesai commented on issue #711: Action: Web (export): Support web-custom-options annotation

pritidesai commented on issue #711: Action: Web (export): Support web-custom-options annotation
URL: https://github.com/apache/incubator-openwhisk-wskdeploy/issues/711#issuecomment-363973973
 
 
   This is supported with `wskdeploy` annotations:
   
   ```
               greeting-web-action-with-custom-options:
                   web-export: true
                   version: 1.0
                   function: src/greeting.js
                   runtime: nodejs:6
                   annotations:
                       web-custom-options: true
   ```
   
   Verification:
   
   ```
   wsk action get IntegrationTestWebAction/greeting-web-action-with-custom-options
   ok: got action IntegrationTestWebAction/greeting-web-action-with-custom-options
   {
       "namespace": "guest/IntegrationTestWebAction",
       "name": "greeting-web-action-with-custom-options",
       "version": "0.0.1",
       "exec": {
           "kind": "nodejs:6",
           "code": "/**\n * Return a simple greeting message for someone.\n *\n * @param name A person's name.\n * @param place Where the person is from.\n */\nfunction main(params) {\n    var name = params.name || params.payload || 'stranger';\n    var place = params.place || 'somewhere';\n    return {payload:  'Hello, ' + name + ' from ' + place + '!'};\n}\n",
           "binary": false
       },
       "annotations": [
           {
               "key": "web-export",
               "value": true
           },
           {
               "key": "web-custom-options",
               "value": true
           },
           {
               "key": "raw-http",
               "value": false
           },
           {
               "key": "final",
               "value": true
           },
           {
               "key": "exec",
               "value": "nodejs:6"
           }
       ],
       "limits": {
           "timeout": 60000,
           "memory": 256,
           "logs": 10
       },
       "publish": false
   }
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services