2
votes

I have a folder structure for lambda as follows created using

serverless create --template aws-python --path base_folder

base_folder
- serverless.yml
- src
- src/handler.py
- src/another_folder
- src/another_folder/file.json

When I run serverless deploy, I do not see the another_folder in the lambda management console on aws.

1

1 Answers

2
votes

You'll have to specify this particular folder inside serverless.yml if it's not specified or referenced from your code files:

service: your_project_name
# your serverless code...
package:
  include:
    src/another_folder/**
# more serverless code...

See the docs on serverless packaging here.

Thanks @dege for pointing out I missed the /** to note the contents of the actual folder