-
Notifications
You must be signed in to change notification settings - Fork 88
Install steps produce failing lambda #2
Comments
Hi Steve, Are you running locally using npm run start or running on aws lambda? When you run locally it will use the dist folder not the actual packaged zip. Double check the Winston folder is there under dist/node_modules/winston. If it is there then I think the directory you are running the npm run start from is not what I expect it to be which is the dynamodb-lambda-autoscale root folder. Please see line 4 of /scripts/start.js to understand why the starting folder is expected to be the root one. |
Sorry should have been clearer. I'm only running it on AWS. My exact steps were: Clone repo |
Let me take a look tonight once I get back to my mac. |
I think it's the permissions that have been set on your node_modules folder. When I download and extract the zip onto my mac I can't even cd into the node_modules folder to see its content. I presume aws lambda is having the same issue. Im not sure why this would be the case, perhaps something todo with your default permissions? Even if you can access the folder it might be that all other users cant.. Im contemplating removing the only node_module dependency (winston) anyway. |
I also had some challenge getting this working when running locally using I'm running on Windows - don't know if that is to blame. I was able to get it to work if I added the access keys to the |
I think your issue is slightly different, I haven't tested windows compatibility. It looks related to motdotla/dotenv#83 and I've opened another issue to cover windows compatibility here #3 |
I just made a commit 357123d which removes all node_modules (i.e. winston) and changes the .env file to config.env. This should sort both your issues. Please let me know if you still get issues though as I haven't been able to test this on a windows machine. |
Get the table names correctly
I followed the install instructions and that attached dist.zip was produced. This however fails on run with the following:
"errorMessage": "Cannot find module 'winston'",
dist.zip
The text was updated successfully, but these errors were encountered: