getlift / lift

Expanding Serverless Framework beyond functions using the AWS CDK
MIT License
920 stars 112 forks source link

Serverless V4: Provider construct is not supported #394

Closed franzs97 closed 5 months ago

franzs97 commented 5 months ago

Description

After updating to serverless v4 it throws an error on deployment/validation:

✖ Provider construct is not supported Error: Provider construct is not supported

How to Reproduce


[...]

provider:
  name: aws
  region: eu-central-1
  [...]
  environment:
    SERVICE_NAME: ${self:service}
    REGION_NAME: ${aws:region}
    TABLE_NAME: ${construct:MyTable.tableName}  # this throws the error

constructs:
  MyTable:
    type: database/dynamodb-single-table
    extensions:
      table:
        Properties:
          TableName: ${self:service}-MyTable

Additional Information

The serverless.yaml still worked in v3.

mnapoli commented 5 months ago

Let's keep discussion in https://github.com/getlift/lift/issues/393#issuecomment-2143057173

Could you please add your comment there? That way it will be visible by the serverless team too.

Thanks!

rj-xy commented 5 months ago

Not ideal for anyone new to using the serverless framework. However v4 has had loads of breaking changes, and this package doesn't work out of the box anymore. We've had to pin serverless to the latest v3.