aws-samples / aws-cost-explorer-report

Python SAM Lambda module for generating an Excel cost report with graphs, including month on month cost changes. Uses the AWS Cost Explorer API for data.
MIT No Attribution
432 stars 166 forks source link

deploy.sh does not work #11

Closed javydekoning closed 6 years ago

javydekoning commented 6 years ago

The original file does not work if the bin folder does not exist (bin folder is not in the repo).

xxx:aws-cost-explorer-report javy$ ./deploy.sh
lambda.zip not found! Downloading one we prepared earlier
wget: bin/lambda.zip: No such file or directory

Solution would be to use curl instead:

curl https://s3.amazonaws.com/aws-cost-explorer-report-bin/lambda.zip --create-dirs -o bin/lambda.zip

Also L21-L23: https://github.com/aws-samples/aws-cost-explorer-report/blob/master/deploy.sh#L21-L23 can be omitted. The lambda.py is already in the deployment package it's added during build

davfaulk commented 6 years ago

Thanks - I agree with issue part 1 - and will fix today as suggested. For part 2, I want someone to be able to not run build (as needs Docker etc), but still modify the lambda (to change reports etc) - so will leave the lambda.py overwrite in deploy.

davfaulk commented 6 years ago

Used "curl https://s3.amazonaws.com/aws-cost-explorer-report-bin/lambda.zip --create-dirs -o bin/lambda.zip" to fix deploy.sh. Thank you.