I am using serverless to deploy lambda to AWS. I have a case that the lambda is defined in functions section but the provision concurrency is configured in resources because I need to use the Condition. The problem I have is that how I can reference the published lambda version from resources?
functions:
getTransactionsHandler:
...
resources:
Conditions:
CommonPCNotZero: !Not [!Equals [0, '${self:custom.commonPC}']]
Resources:
!If
- CommonPCNotZero
- getTransactionsHandler:
Type: AWS::Lambda::Alias
Properties:
FunctionName: !Ref GetTransactionsHandlerLambdaFunction
FunctionVersion: HOW CAN I GET THE VERSION?
ProvisionedConcurrencyConfig:
ProvisionedConcurrentExecutions: '${self:custom.commonPC}'
- !Ref AWS::NoValue