namely / docker-protoc

Docker images for generating protocol buffer definitions
BSD 3-Clause "New" or "Revised" License
729 stars 225 forks source link

Multiple files in directory #251

Open pablodz opened 3 years ago

pablodz commented 3 years ago

Hello there, I was trying to compile all proto files in a repo with a folder structure similar to:

./internal/v1/services/grpc_apinode/apinode_api.proto
./internal/v1/services/grpc_nlp/agent/agent_api.proto
./internal/v1/services/grpc_nlp/classification/classification_api.proto
./internal/v1/conversation/conversation.proto
./internal/v1/campaign/campaign.proto
./internal/v1/comment/comment.proto
./internal/v1/agent/agent.proto
./internal/v1/variable/variable.proto

However when I put -d internal/v1 dockers prints Missing input file.

docker run --rm -v `pwd`:/defs --name prueba namely/protoc-all -d internal/v1 -l go -o docker-generated

What am I doing wrong? Thanks in advance

pablodz commented 3 years ago

https://github.com/namely/docker-protoc/blob/89631f00bc21607a8b4bc45b896d98754c4fd0b8/all/entrypoint.sh#L425-L426

I think maxdepth should be more by default, not 1 for golang

eleduardo commented 2 years ago

I am facing this exact problem as well... why is there a limit in the depth of find? if you docker run into the container and do this manually you can see that running the find command does not find any of the proto files (I have a similar structure) should that maxdepth be removed?