aws / chalice

Python Serverless Microframework for AWS
Apache License 2.0
10.62k stars 1.01k forks source link

Using --project-dir option #940

Open hx2A opened 6 years ago

hx2A commented 6 years ago

When deploying a package this works fine to deploy a package:

$ cd quickdraw-lambdas/
$ chalice deploy --no-autogen-policy

but this does not:

$ cd ..
$ chalice --project-dir "quickdraw-lambdas/" deploy --no-autogen-policy

I get the error message:

FileNotFoundError: [Errno 2] No such file or directory: 'quickdraw-lambdas/.chalice/config.json'

Even though that file exists:

$ ll quickdraw-lambdas/.chalice/config.json
-rw-rw-r-- 1 jim jim 129 Aug 18 21:07 quickdraw-lambdas/.chalice/config.json

I can change that directory to an absolute path to make it work but I want it to be relative. I do see issue #414 . Is it supposed to work this way? Is there a way to specify a relative path?

Thanks

kyleknap commented 5 years ago

It looks like as of now it does not support relative paths. However, I am inclined to support relative paths. It is tedious to always specify absolute paths. @jamesls @stealthycoin any thoughts?

It looks like the issue you linked aims to fix it. So I would recommend following that PR.