@malagu/scf-adapter component to deploy applications in SCF. Based on the principle of convention over configuration, the component can be used out of the box with zero configuration required.stage configuration attribute to represent the environment. In the deployment rule agreed by the @malagu/scf-adapter component, the mode attribute is used to map the stage attribute. Three environments are provided by default: testing, prerelease, and production. The expression rule is as follows:stage: "${'test' in mode ? 'test' : 'pre' in mode ? 'pre' : 'prod' in mode ? 'prod' : cliContext.prod ? 'prod' : 'test'}" # test, pre, prod
stage value rule is as follows:mode attribute contains the test mode, or mode does not contain test, pre, and prod and the command line parameter -p,--prod is not specified.mode attribute contains the pre mode.mode attribute contains the prod mode, or the command line parameter -p,--prod is specified.mode:# Deploy to the test environmentmalagu deploy -m test # Or use `malagu deploy`# Deploy to the prerelease environment. You can also skip deploying to the prerelease environment and deploy directly to the production environmentmalagu deploy -m pre# Deploy to the production environmentmalagu deploy -m prod
stage attribute value with the service alias (the following is the default rule and does not need to be configured):malagu:faas-adapter:alias:name: ${stage}
malagu:faas-adapter:apiGateway:release:environmentName: "${stage == 'pre' ? 'prepub' : stage == 'prod' ? 'release' : stage}"
mode attribute. Supported deployment modes include:mode:- http
malagu-remote.yml configuration file of the @malagu/scf-adapter component.mode:- htpp # Valid values: http, timer, api-gateway. Default value: http
malagu:faas-adapter:namespace:name: xxxx # The default value is `default`
malagu:faas-adapter:function:name: xxxx # The default value is `${pkg.name}`
malagu:faas-adapter:type:namespace:description:function:name: ''namespace:handler:publish:l5Enable:type:codeSource:description:memorySize:timeout:runtime:role:clsLogsetId:ClsTopicId:env:vpcConfig:vpcId:subnetId:layers:name:version:deadLetterConfig:type:name:filterType:publicNetConfig:PublicNetStatus:eipConfig:eipStatus:alias:name:functionName:namespace:description:routingConfig:additionalVersionWeights:version:weight:addtionVersionMatchs:version:key:method:expression:apiGateway:usagePlan:name:environment:desc:maxRequestNum:maxRequestNumPreSec:strategy:name:environmentName:strategy:api:name:serviceTimeout:protocol:desc:authType:enableCORS:businessType:serviceScfFunctionName:serviceWebsocketTransportFunctionName:serviceScfFunctionNamespace:serviceScfFunctionQualifier:serviceWebsocketTransportFunctionNamespace:serviceWebsocketTransportFunctionQualifier:isDebugAfterCharge:serviceScfIsIntegratedResponse:isDeleteResponseErrorCodes:responseSuccessExample:responseFailExample:authRelationApiId:userType:oauthConfig:publicKey:tokenLocation:loginRedirectUrl:responseErrorCodes:code:msg:desc:convertedCode:needConvert:requestConfig:ApiRequestConfig:path:method:requestParameters:name:desc:position:type:defaultValue:required:RequestParameter:service:exclusiveSetName:name:protocol:description:netTypes:ipVersion:setServerName:appIdType:release:environmentName:desc:customDomain:name:isDefaultMapping:certificateId:protocol:netType:pathMappingSet:path:Environment:
Feedback