From fbb49a94976dd70e3f16cd97521998b89c2c49aa Mon Sep 17 00:00:00 2001 From: Shakir <30622440+networkandcode@users.noreply.github.com> Date: Tue, 2 Aug 2022 17:41:20 +0530 Subject: [PATCH] allow dashes in label keys sls deploy was throwing a configuration error when dashes are used in keys. ``` $ serverless deploy Running "serverless" from node_modules Warning: Invalid configuration encountered at 'provider.labels': unrecognized property 'created-by' Learn more about configuration validation here: http://slss.io/configuration-validation ``` I think dashes can be included according to the google documentation. https://cloud.google.com/deployment-manager/docs/creating-managing-labels --- provider/googleProvider.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/provider/googleProvider.js b/provider/googleProvider.js index 00bbd85..8c2bf90 100644 --- a/provider/googleProvider.js +++ b/provider/googleProvider.js @@ -126,7 +126,7 @@ class GoogleProvider { maxLength: 63, }, patternProperties: { - '^[a-z][a-z0-9_.]*$': { type: 'string' }, + '^[a-z][a-z0-9_.-]*$': { type: 'string' }, }, additionalProperties: false, },