Use serverless without lambda function

Hi, is there any way to use serverless without configuration for lambda function. I try to create serveless.yml without functions attribute and some of the attributes have not been created inside final cloudformation file (APIGatewayDeployment, ApiGatewayRestApi, …). I use mainly resources attributes in serverless.yml.

1 Like

@themyth92 You can use Serverless without any Lambda functions, and it’s a pattern we see a lot with people to provision infrastructure that may be more permanent than a particular service.

Are you defining APIGatewayDeployment and ApiGatewayRestApi in your stack? Right now, Serverless will only provision those if you have a Lambda function with an http event hooked up to it. If you don’t have those, you’ll have to write the CloudFormation yourself in the resources section.

3 Likes

Ok, really appreciate your response :slight_smile: