Skip to content

Commit

Permalink
fix: Aws provisioned concurrency config. (#616)
Browse files Browse the repository at this point in the history
  • Loading branch information
tjholm authored May 14, 2024
1 parent b69ea25 commit 15c1b16
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions cloud/aws/deploy/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,7 @@ func (a *NitricAwsPulumiProvider) Service(ctx *pulumi.Context, parent pulumi.Res
ImageUri: image.URI(),
MemorySize: pulumi.IntPtr(typeConfig.Lambda.Memory),
Timeout: pulumi.IntPtr(typeConfig.Lambda.Timeout),
Publish: pulumi.BoolPtr(true),
PackageType: pulumi.String("Image"),
Role: a.LambdaRoles[name].Arn,
Tags: pulumi.ToStringMap(tags.Tags(a.StackId, name, resources.Service)),
Expand All @@ -242,11 +243,11 @@ func (a *NitricAwsPulumiProvider) Service(ctx *pulumi.Context, parent pulumi.Res
}

if typeConfig.Lambda.ProvisionedConcurreny > 0 {
_, err := awslambda.NewProvisionedConcurrencyConfig(ctx, name, &awslambda.ProvisionedConcurrencyConfigArgs{
_, err = awslambda.NewProvisionedConcurrencyConfig(ctx, name, &awslambda.ProvisionedConcurrencyConfigArgs{
FunctionName: a.Lambdas[name].Arn,
ProvisionedConcurrentExecutions: pulumi.Int(typeConfig.Lambda.ProvisionedConcurreny),
Qualifier: a.Lambdas[name].Name,
})
Qualifier: a.Lambdas[name].Version,
}, pulumi.DependsOn([]pulumi.Resource{a.Lambdas[name]}))
if err != nil {
return err
}
Expand Down

0 comments on commit 15c1b16

Please sign in to comment.