diff --git a/serverless.component.yml b/serverless.component.yml index 8dc0c06..ab73b9c 100644 --- a/serverless.component.yml +++ b/serverless.component.yml @@ -1,5 +1,5 @@ name: websocket -version: 0.3.0 +version: 0.3.1 author: Tencent Cloud, Inc. org: Tencent Cloud, Inc. description: Deploys websocket service on Tencent Cloud. diff --git a/src/config.js b/src/config.js index da8fccb..33e7939 100644 --- a/src/config.js +++ b/src/config.js @@ -2,7 +2,7 @@ const CONFIGS = { compName: 'websocket', compFullname: 'Websocket', defaultEntryFile: 'sls.js', - handler: 'handler.socket', + handler: 'handler.handler', region: 'ap-guangzhou', runtime: 'Nodejs10.15', namespace: 'default', diff --git a/src/serverless.js b/src/serverless.js index d01b025..a673a6a 100644 --- a/src/serverless.js +++ b/src/serverless.js @@ -206,9 +206,6 @@ class ServerlessComponent extends Component { const [faasOutputs, apigwOutputs = {}] = await Promise.all(deployTasks) const { wsBackUrl } = apigwOutputs[regionList[0]] - this.state.wsBackUrl = wsBackUrl - outputs.wsBackUrl = wsBackUrl - await this.updateFaas(credentials, faasConfig, regionList, wsBackUrl) // optimize outputs for one region @@ -216,10 +213,10 @@ class ServerlessComponent extends Component { const [oneRegion] = regionList outputs.region = oneRegion outputs['apigw'] = apigwOutputs[oneRegion] - outputs['scf'] = faasOutputs[oneRegion] + outputs['faas'] = faasOutputs[oneRegion] } else { outputs['apigw'] = apigwOutputs - outputs['scf'] = faasOutputs + outputs['faas'] = faasOutputs } this.state.region = regionList[0]