mrserverless / serverless-golang

AWS Lambda Go functions using Serverless Framework and Python shim
Other
302 stars 21 forks source link

make package return error #10

Closed lielran closed 7 years ago

lielran commented 7 years ago

I just sls install by the example and try to run make package it ends up with this error:

package company.com/hello-world: directory "/Users/XXXX/golang/src/company.com/hello-world" is not using a known version control system
make: *** [deps] Error 1
lielran commented 7 years ago

update: I did a go get for all the needed dependencies and remove the depds command. and it works fine

mrserverless commented 7 years ago

thanks for the report @lielran. Out of curiosity which example did you install? aws/event or aws/net?

I think I know what the issue is. Will investigate and fix

lielran commented 7 years ago

Aws event

mrserverless commented 7 years ago

this has been resolved in https://github.com/yunspace/serverless-golang/commit/5497279cf24a59a74a104c75a6a75d4c26e51c20

the is not using a known version control system error is caused by go get -u trying to do an update on the current project which isn't in source control. However, if I add a git init, it will cause errors with remote origin not found. So in the end I just removed the -u flag.

Proper vendor based dependency management and update will be addressed as part of #11

mrserverless commented 7 years ago

@lielran note also I've changed the directory structure to cater for more examples in the future. The installation command is now:

serverless install -u https://github.com/yunspace/serverless-golang/tree/master/examples/aws-golang-event -n your-project

and make deploy will use a docker container do serverless deploy

lielran commented 7 years ago

cool. I'll give it a try