I have structured my code in the following directories:
|-my-project
|- folder
|-function1.js
|-function2.js
|-function3.js
|-serverless.yml
All functions are structured in their own files, inside a folder. In the same location as the folder, I have a serverless.yml file, which describes those functions.
When I deploy them via the Serverless command, it uploads everything nicely and it creates a Lambda function in AWS for each declared function in my serverless.yml. However, I can’t access the code, as I get the following message in the AWS dashboard:
This function contains external libraries. Uploading a new file will override these libraries.
Is there a way of putting these functions in their own files, declaring them in the serverless.yml file, upload them and still being able to see the actual code in the AWS console? I’ve already tried multiple variations, but none of them worked:
- folder.function1.functionname
- functionname
None of these options seems to work.