├── .dockerignore ├── .gitignore ├── .vscode ├── extensions.json ├── launch.json ├── settings.json └── tasks.json ├── Dockerfile ├── LICENSE ├── QueueTrigger ├── function.json └── index.js ├── README.md ├── docs └── storageexplorer.png ├── host.json ├── local.settings.json.sample └── package.json /.dockerignore: -------------------------------------------------------------------------------- 1 | local.settings.json -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | bin 2 | obj 3 | csx 4 | .vs 5 | edge 6 | Publish 7 | bin/ 8 | obj/ 9 | 10 | *.user 11 | *.suo 12 | *.cscfg 13 | *.Cache 14 | project.lock.json 15 | 16 | /packages 17 | /TestResults 18 | 19 | /tools/NuGet.exe 20 | /App_Data 21 | /secrets 22 | /data 23 | .secrets 24 | appsettings.json 25 | local.settings.json 26 | 27 | node_modules 28 | dist 29 | 30 | # Local python packages 31 | .python_packages/ 32 | 33 | # Python Environments 34 | .env 35 | .venv 36 | env/ 37 | venv/ 38 | ENV/ 39 | env.bak/ 40 | venv.bak/ 41 | 42 | # Byte-compiled / optimized / DLL files 43 | __pycache__/ 44 | *.py[cod] 45 | *$py.class 46 | 47 | # Managed dependencies folder 48 | ManagedDependencies/ 49 | 50 | .DS_Store -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | "recommendations": [ 3 | "ms-azuretools.vscode-azurefunctions" 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.2.0", 3 | "configurations": [ 4 | { 5 | "name": "Attach to Node Functions", 6 | "type": "node", 7 | "request": "attach", 8 | "port": 9229, 9 | "preLaunchTask": "func: host start" 10 | } 11 | ] 12 | } 13 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "azureFunctions.projectRuntime": "~2", 3 | "azureFunctions.projectLanguage": "JavaScript", 4 | "azureFunctions.deploySubpath": ".", 5 | "azureFunctions.preDeployTask": "func: extensions install", 6 | "files.exclude": { 7 | "obj": true, 8 | "bin": true 9 | }, 10 | "debug.internalConsoleOptions": "neverOpen" 11 | } 12 | -------------------------------------------------------------------------------- /.vscode/tasks.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0.0", 3 | "tasks": [ 4 | { 5 | "type": "func", 6 | "command": "host start", 7 | "problemMatcher": "$func-watch", 8 | "dependsOn": "func: extensions install", 9 | "isBackground": true 10 | } 11 | ] 12 | } 13 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM mcr.microsoft.com/azure-functions/node:2.0 2 | 3 | ENV AzureWebJobsScriptRoot=/home/site/wwwroot 4 | ENV AzureFunctionsJobHost__Logging__Console__IsEnabled=true 5 | COPY . /home/site/wwwroot -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | 2 | Apache License 3 | Version 2.0, January 2004 4 | http://www.apache.org/licenses/ 5 | 6 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 7 | 8 | 1. Definitions. 9 | 10 | "License" shall mean the terms and conditions for use, reproduction, 11 | and distribution as defined by Sections 1 through 9 of this document. 12 | 13 | "Licensor" shall mean the copyright owner or entity authorized by 14 | the copyright owner that is granting the License. 15 | 16 | "Legal Entity" shall mean the union of the acting entity and all 17 | other entities that control, are controlled by, or are under common 18 | control with that entity. For the purposes of this definition, 19 | "control" means (i) the power, direct or indirect, to cause the 20 | direction or management of such entity, whether by contract or 21 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 22 | outstanding shares, or (iii) beneficial ownership of such entity. 23 | 24 | "You" (or "Your") shall mean an individual or Legal Entity 25 | exercising permissions granted by this License. 26 | 27 | "Source" form shall mean the preferred form for making modifications, 28 | including but not limited to software source code, documentation 29 | source, and configuration files. 30 | 31 | "Object" form shall mean any form resulting from mechanical 32 | transformation or translation of a Source form, including but 33 | not limited to compiled object code, generated documentation, 34 | and conversions to other media types. 35 | 36 | "Work" shall mean the work of authorship, whether in Source or 37 | Object form, made available under the License, as indicated by a 38 | copyright notice that is included in or attached to the work 39 | (an example is provided in the Appendix below). 40 | 41 | "Derivative Works" shall mean any work, whether in Source or Object 42 | form, that is based on (or derived from) the Work and for which the 43 | editorial revisions, annotations, elaborations, or other modifications 44 | represent, as a whole, an original work of authorship. For the purposes 45 | of this License, Derivative Works shall not include works that remain 46 | separable from, or merely link (or bind by name) to the interfaces of, 47 | the Work and Derivative Works thereof. 48 | 49 | "Contribution" shall mean any work of authorship, including 50 | the original version of the Work and any modifications or additions 51 | to that Work or Derivative Works thereof, that is intentionally 52 | submitted to Licensor for inclusion in the Work by the copyright owner 53 | or by an individual or Legal Entity authorized to submit on behalf of 54 | the copyright owner. For the purposes of this definition, "submitted" 55 | means any form of electronic, verbal, or written communication sent 56 | to the Licensor or its representatives, including but not limited to 57 | communication on electronic mailing lists, source code control systems, 58 | and issue tracking systems that are managed by, or on behalf of, the 59 | Licensor for the purpose of discussing and improving the Work, but 60 | excluding communication that is conspicuously marked or otherwise 61 | designated in writing by the copyright owner as "Not a Contribution." 62 | 63 | "Contributor" shall mean Licensor and any individual or Legal Entity 64 | on behalf of whom a Contribution has been received by Licensor and 65 | subsequently incorporated within the Work. 66 | 67 | 2. Grant of Copyright License. Subject to the terms and conditions of 68 | this License, each Contributor hereby grants to You a perpetual, 69 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 70 | copyright license to reproduce, prepare Derivative Works of, 71 | publicly display, publicly perform, sublicense, and distribute the 72 | Work and such Derivative Works in Source or Object form. 73 | 74 | 3. Grant of Patent License. Subject to the terms and conditions of 75 | this License, each Contributor hereby grants to You a perpetual, 76 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 77 | (except as stated in this section) patent license to make, have made, 78 | use, offer to sell, sell, import, and otherwise transfer the Work, 79 | where such license applies only to those patent claims licensable 80 | by such Contributor that are necessarily infringed by their 81 | Contribution(s) alone or by combination of their Contribution(s) 82 | with the Work to which such Contribution(s) was submitted. If You 83 | institute patent litigation against any entity (including a 84 | cross-claim or counterclaim in a lawsuit) alleging that the Work 85 | or a Contribution incorporated within the Work constitutes direct 86 | or contributory patent infringement, then any patent licenses 87 | granted to You under this License for that Work shall terminate 88 | as of the date such litigation is filed. 89 | 90 | 4. Redistribution. You may reproduce and distribute copies of the 91 | Work or Derivative Works thereof in any medium, with or without 92 | modifications, and in Source or Object form, provided that You 93 | meet the following conditions: 94 | 95 | (a) You must give any other recipients of the Work or 96 | Derivative Works a copy of this License; and 97 | 98 | (b) You must cause any modified files to carry prominent notices 99 | stating that You changed the files; and 100 | 101 | (c) You must retain, in the Source form of any Derivative Works 102 | that You distribute, all copyright, patent, trademark, and 103 | attribution notices from the Source form of the Work, 104 | excluding those notices that do not pertain to any part of 105 | the Derivative Works; and 106 | 107 | (d) If the Work includes a "NOTICE" text file as part of its 108 | distribution, then any Derivative Works that You distribute must 109 | include a readable copy of the attribution notices contained 110 | within such NOTICE file, excluding those notices that do not 111 | pertain to any part of the Derivative Works, in at least one 112 | of the following places: within a NOTICE text file distributed 113 | as part of the Derivative Works; within the Source form or 114 | documentation, if provided along with the Derivative Works; or, 115 | within a display generated by the Derivative Works, if and 116 | wherever such third-party notices normally appear. The contents 117 | of the NOTICE file are for informational purposes only and 118 | do not modify the License. You may add Your own attribution 119 | notices within Derivative Works that You distribute, alongside 120 | or as an addendum to the NOTICE text from the Work, provided 121 | that such additional attribution notices cannot be construed 122 | as modifying the License. 123 | 124 | You may add Your own copyright statement to Your modifications and 125 | may provide additional or different license terms and conditions 126 | for use, reproduction, or distribution of Your modifications, or 127 | for any such Derivative Works as a whole, provided Your use, 128 | reproduction, and distribution of the Work otherwise complies with 129 | the conditions stated in this License. 130 | 131 | 5. Submission of Contributions. Unless You explicitly state otherwise, 132 | any Contribution intentionally submitted for inclusion in the Work 133 | by You to the Licensor shall be under the terms and conditions of 134 | this License, without any additional terms or conditions. 135 | Notwithstanding the above, nothing herein shall supersede or modify 136 | the terms of any separate license agreement you may have executed 137 | with Licensor regarding such Contributions. 138 | 139 | 6. Trademarks. This License does not grant permission to use the trade 140 | names, trademarks, service marks, or product names of the Licensor, 141 | except as required for reasonable and customary use in describing the 142 | origin of the Work and reproducing the content of the NOTICE file. 143 | 144 | 7. Disclaimer of Warranty. Unless required by applicable law or 145 | agreed to in writing, Licensor provides the Work (and each 146 | Contributor provides its Contributions) on an "AS IS" BASIS, 147 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 148 | implied, including, without limitation, any warranties or conditions 149 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 150 | PARTICULAR PURPOSE. You are solely responsible for determining the 151 | appropriateness of using or redistributing the Work and assume any 152 | risks associated with Your exercise of permissions under this License. 153 | 154 | 8. Limitation of Liability. In no event and under no legal theory, 155 | whether in tort (including negligence), contract, or otherwise, 156 | unless required by applicable law (such as deliberate and grossly 157 | negligent acts) or agreed to in writing, shall any Contributor be 158 | liable to You for damages, including any direct, indirect, special, 159 | incidental, or consequential damages of any character arising as a 160 | result of this License or out of the use or inability to use the 161 | Work (including but not limited to damages for loss of goodwill, 162 | work stoppage, computer failure or malfunction, or any and all 163 | other commercial damages or losses), even if such Contributor 164 | has been advised of the possibility of such damages. 165 | 166 | 9. Accepting Warranty or Additional Liability. While redistributing 167 | the Work or Derivative Works thereof, You may choose to offer, 168 | and charge a fee for, acceptance of support, warranty, indemnity, 169 | or other liability obligations and/or rights consistent with this 170 | License. However, in accepting such obligations, You may act only 171 | on Your own behalf and on Your sole responsibility, not on behalf 172 | of any other Contributor, and only if You agree to indemnify, 173 | defend, and hold each Contributor harmless for any liability 174 | incurred by, or claims asserted against, such Contributor by reason 175 | of your accepting any such warranty or additional liability. 176 | 177 | END OF TERMS AND CONDITIONS 178 | 179 | APPENDIX: How to apply the Apache License to your work. 180 | 181 | To apply the Apache License to your work, attach the following 182 | boilerplate notice, with the fields enclosed by brackets "[]" 183 | replaced with your own identifying information. (Don't include 184 | the brackets!) The text should be enclosed in the appropriate 185 | comment syntax for the file format. We also recommend that a 186 | file or class name and description of purpose be included on the 187 | same "printed page" as the copyright notice for easier 188 | identification within third-party archives. 189 | 190 | Copyright 2020 The KEDA Authors. 191 | 192 | and others that have contributed code to the public domain. 193 | 194 | Licensed under the Apache License, Version 2.0 (the "License"); 195 | you may not use this file except in compliance with the License. 196 | You may obtain a copy of the License at 197 | 198 | http://www.apache.org/licenses/LICENSE-2.0 199 | 200 | Unless required by applicable law or agreed to in writing, software 201 | distributed under the License is distributed on an "AS IS" BASIS, 202 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 203 | See the License for the specific language governing permissions and 204 | limitations under the License. 205 | -------------------------------------------------------------------------------- /QueueTrigger/function.json: -------------------------------------------------------------------------------- 1 | { 2 | "bindings": [ 3 | { 4 | "name": "myQueueItem", 5 | "type": "queueTrigger", 6 | "direction": "in", 7 | "queueName": "js-queue-items", 8 | "connection": "AzureWebJobsStorage" 9 | } 10 | ] 11 | } -------------------------------------------------------------------------------- /QueueTrigger/index.js: -------------------------------------------------------------------------------- 1 | module.exports = async function (context, myQueueItem) { 2 | context.log('JavaScript queue trigger function processed work item', myQueueItem); 3 | }; -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # KEDA and Azure Functions with queues sample 2 | 3 | This sample goes through the basics of creating an Azure Function that triggers on a new Azure Storage Queue message. The function can then be deployed to Kubernetes with KEDA for event driven activation and scale. 4 | 5 | ## Pre-requisites 6 | 7 | * [Azure Function Core Tools v3](https://github.com/azure/azure-functions-core-tools#installing). Makes sure the version is greater than: 3.0.3216 8 | * An Azure Subscription (to host the storage queue). A free account works great - [https://azure.com/free](http://azure.com/free) 9 | * Kubernetes cluster (can be [AKS](https://docs.microsoft.com/en-us/azure/aks/kubernetes-walkthrough-portal), GKE, EKS, OpenShift etc.) and [`kubectl`](https://kubernetes.io/docs/tasks/tools/install-kubectl/) pointing to your Kubernetes cluster (for [AKS](https://docs.microsoft.com/en-us/azure/aks/kubernetes-walkthrough#connect-to-the-cluster)). NOTE: If you want to use KEDA with Azure Virtual Nodes, be sure to [enable Virtual Nodes](https://docs.microsoft.com/en-us/azure/aks/virtual-nodes-portal) at create. 10 | * Docker and a Docker registry 11 | 12 | ## Tutorial 13 | 14 | #### 1. Create a new directory for the function app 15 | 16 | ```cli 17 | mkdir hello-keda 18 | cd hello-keda 19 | ``` 20 | 21 | #### 2. Initialize the directory for functions 22 | 23 | ```cli 24 | func init . --docker 25 | ``` 26 | 27 | Select **node** and **JavaScript** 28 | 29 | #### 3. Add a new queue triggered function 30 | 31 | ```cli 32 | func new 33 | ``` 34 | 35 | Select **Azure Queue Storage Trigger** 36 | 37 | Leave the default of `QueueTrigger` for the name 38 | 39 | #### 4. Create an Azure storage queue 40 | 41 | We'll create a storage account and a queue named `js-queue-items` 42 | 43 | You can use the [Azure CLI](https://docs.microsoft.com/cli/azure/install-azure-cli?view=azure-cli-latest), the [Azure cloud shell](https://shell.azure.com), or [the Azure portal](https://docs.microsoft.com/azure/storage/common/storage-quickstart-create-account#create-a-storage-account-1). The following is how you do it using Azure CLI. 44 | 45 | `` would be replaced by a unique storage account name. 46 | 47 | ```cli 48 | az group create -l westus -n hello-keda 49 | az storage account create --sku Standard_LRS --location westus -g hello-keda -n 50 | 51 | CONNECTION_STRING=$(az storage account show-connection-string --name --query connectionString) 52 | 53 | az storage queue create -n js-queue-items --connection-string $CONNECTION_STRING 54 | ``` 55 | 56 | #### 5. Update the function metadata with the storage account info 57 | 58 | Open the `hello-keda` directory in an editor. We'll need to update the connection string info for the queue trigger, and make sure the queue trigger capabilities are installed. 59 | 60 | Copy the current storage account connection string (HINT: don't include the `"`) 61 | 62 | ```cli 63 | az storage account show-connection-string --name --query connectionString 64 | ``` 65 | 66 | Open `local.settings.json` which has the local debug connection string settings. Replace the `{AzureWebJobsStorage}` with the connection string value: 67 | 68 | **local.settings.json** 69 | ```json 70 | { 71 | "IsEncrypted": false, 72 | "Values": { 73 | "FUNCTIONS_WORKER_RUNTIME": "node", 74 | "AzureWebJobsStorage": "DefaultEndpointsProtocol=https;EndpointSuffix=core.windows.net;AccountName=mystorageaccount;AccountKey=shhhh===" 75 | } 76 | } 77 | ``` 78 | 79 | Finally, open the `QueueTrigger/function.json` file and set the `connection` setting value to `AzureWebJobsStorage`. This tells the function to pull the connection string from the `AzureWebJobsStorage` key we set above. 80 | 81 | **function.json** 82 | ```json 83 | { 84 | "bindings": [ 85 | { 86 | "name": "myQueueItem", 87 | "type": "queueTrigger", 88 | "direction": "in", 89 | "queueName": "js-queue-items", 90 | "connection": "AzureWebJobsStorage" 91 | } 92 | ] 93 | } 94 | ``` 95 | 96 | #### 6. Enable the storage queue bundle on the function runtime 97 | 98 | Replace the `host.json` content with the following. This [pulls in the extensions to the function runtime](https://docs.microsoft.com/azure/azure-functions/functions-bindings-register#local-development-with-azure-functions-core-tools-and-extension-bundles) like Azure Storage Queues support. 99 | 100 | **host.json** 101 | ```json 102 | { 103 | "version": "2.0", 104 | "extensionBundle": { 105 | "id": "Microsoft.Azure.Functions.ExtensionBundle", 106 | "version": "[1.*, 2.0.0)" 107 | } 108 | } 109 | ``` 110 | 111 | #### 7. Debug and test the function locally (optional) 112 | 113 | Start the function locally 114 | ```cli 115 | func start 116 | ``` 117 | 118 | Go to your Azure Storage account in the [Azure Portal](https://portal.azure.com) and open the **Storage Explorer**. Select the `js-queue-items` queue and add a message to send to the function. 119 | 120 | ![Azure portal storage explorer](docs/storageexplorer.png) 121 | 122 | You should see your function running locally fired correctly immediately 123 | 124 | ```cli 125 | [5/1/19 6:00:53 AM] Executing 'Functions.QueueTrigger' (Reason='New queue message detected on 'js-queue-items'.', Id=2beeca56-4c7a-4af9-b15a-86d896d55a92) 126 | [5/1/19 6:00:53 AM] Trigger Details: MessageId: 60c80a55-e941-4f78-bb93-a1ef006c3dc5, DequeueCount: 1, InsertionTime: 5/1/19 6:00:53 AM +00:00 127 | [5/1/19 6:00:53 AM] JavaScript queue trigger function processed work item Hello KEDA 128 | [5/1/19 6:00:53 AM] Executed 'Functions.QueueTrigger' (Succeeded, Id=2beeca56-4c7a-4af9-b15a-86d896d55a92) 129 | ``` 130 | 131 | #### 8. Install KEDA 132 | 133 | [Follow the instructions](https://keda.sh/docs/2.0/deploy/) to deploy KEDA in your cluster. 134 | 135 | To confirm that KEDA has successfully installed you can run the following command and should see the following CRD. 136 | 137 | ```cli 138 | kubectl get customresourcedefinition 139 | NAME AGE 140 | scaledobjects.keda.sh 2h 141 | scaledjobs.keda.sh 2h 142 | ``` 143 | 144 | #### 9a. Deploy Function App to KEDA (standard) 145 | 146 | You can then deploy your function to Kubernetes. If you want to deploy so that the function may run on Virtual Nodes, [follow 9b](#9b-deploy-function-app-to-keda-virtual-nodes) 147 | 148 | First log in to docker from the command line with your user Id and password 149 | ```cli 150 | docker login 151 | ``` 152 | Make sure you have created a private repo in docker.io to which your container image will be pushed. 153 | 154 | ```cli 155 | func kubernetes deploy --name hello-keda --registry 156 | ``` 157 | 158 | This will build the docker container, push it to the specified registry, and deploy it to Kubernetes. You can see the actual generated deployment with the `--dry-run` flag. 159 | 160 | #### 9b. Deploy Function App to KEDA (Virtual Nodes) 161 | 162 | To deploy your function Kubernetes with Azure Virtual Nodes, you need to modify the details of the deployment to allow the selection of virtual nodes. 163 | 164 | Generate a deployment yaml for the function. 165 | ```cli 166 | func kubernetes deploy --name hello-keda --registry --javascript --dry-run > deploy.yaml 167 | ``` 168 | 169 | Open and modify the created `deploy.yaml` to tolerate scheduling onto any nodes, including virtual. 170 | 171 | ```yaml 172 | spec: 173 | containers: 174 | - name: hello-keda 175 | image: /hello-keda 176 | env: 177 | - name: AzureFunctionsJobHost__functions__0 178 | value: QueueTrigger 179 | envFrom: 180 | - secretRef: 181 | name: hello-keda 182 | tolerations: 183 | - operator: Exists 184 | ``` 185 | 186 | Build and deploy the container image, and apply the deployment to your cluster. 187 | ```cli 188 | docker build -t /hello-keda . 189 | docker push /hello-keda 190 | 191 | kubectl apply -f deploy.yaml 192 | ``` 193 | 194 | #### 10. Add a queue message and validate the function app scales with KEDA 195 | 196 | Initially after deploy and with an empty queue you should see 0 pods. 197 | 198 | ```cli 199 | kubectl get deploy 200 | ``` 201 | 202 | Add a queue message to the queue (using the Storage Explorer shown in step 7 above). KEDA will detect the event and add a pod. By default the polling interval set is 30 seconds on the `ScaledObject` resource, so it may take up to 30 seconds for the queue message to be detected and activate your function. This can be [adjusted on the `ScaledObject` resource](https://github.com/kedacore/keda/wiki/ScaledObject-spec). 203 | 204 | ```cli 205 | kubectl get pods -w 206 | ``` 207 | 208 | The queue message will be consumed. You can validate the message was consumed by using `kubectl logs` on the activated pod. New queue messages will be consumed and if enough queue messages are added the function will autoscale. After all messages are consumed and the cooldown period has elapsed (default 300 seconds), the last pod should scale back down to zero. 209 | 210 | ## Cleaning up resources 211 | 212 | #### Delete the function deployment 213 | 214 | ```cli 215 | kubectl delete deploy hello-keda 216 | kubectl delete ScaledObject hello-keda 217 | kubectl delete Secret hello-keda 218 | ``` 219 | 220 | #### Delete the storage account 221 | 222 | ```cli 223 | az storage account delete --name 224 | ``` 225 | 226 | #### Uninstall KEDA 227 | 228 | ```cli 229 | func kubernetes remove --namespace keda 230 | ``` 231 | -------------------------------------------------------------------------------- /docs/storageexplorer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kedacore/sample-hello-world-azure-functions/a67b656f55713f7b3f6ccddd65cfe868e683f7ba/docs/storageexplorer.png -------------------------------------------------------------------------------- /host.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "extensionBundle": { 4 | "id": "Microsoft.Azure.Functions.ExtensionBundle", 5 | "version": "[1.*, 2.0.0)" 6 | } 7 | } -------------------------------------------------------------------------------- /local.settings.json.sample: -------------------------------------------------------------------------------- 1 | { 2 | "IsEncrypted": false, 3 | "Values": { 4 | "FUNCTIONS_WORKER_RUNTIME": "node", 5 | "AzureWebJobsStorage": "" 6 | } 7 | } -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "", 3 | "version": "", 4 | "description": "", 5 | "scripts" : { 6 | "test": "echo \"No tests yet...\"" 7 | }, 8 | "author": "" 9 | } --------------------------------------------------------------------------------