Closed bkircher67 closed 6 years ago
Thanks for your report.
This repository was extracted from our TheThingsNetwork/ttn
repository, and heavily depends on Go and some Go dependencies. I'll try to update the README and Makefile to work around this.
Hi @bkircher67, could you try again with the newest master branch?
I likewise have problems:
[vagrant@localhost api]$ make clean all
find . -name '*pb.go' -delete
find . -name '*pb.gw.go' -delete
rm -rf java/src/org/thethingsnetwork/api
find . -name '*_pb.js' -delete
rm -rf php/*
find . -name '*_pb.rb' -delete
find . -name '*_pb2.py' -delete
find . -name '*_pb2_grpc.py' -delete
rm -rf python/github python/github.com
rm -rf c/github.com/TheThingsNetwork
find . -name '*.swift' -delete
find . -name '*_mock.go' -delete
docker build -t thethingsnetwork/api-protoc:latest .
Sending build context to Docker daemon 3.24 MB
Step 1/7 : FROM golang:1.10 AS go_builder
Error parsing reference: "golang:1.10 AS go_builder" is not a valid repository/tag: invalid reference format
make: *** [docker] Error 1
It seems like the intent is to use Docker to encapsulate the protobuf API code generation build process. If so, it would probably make sense to also isolate and containerize the Golang dependencies from the host system.
Are you on a recent version of Docker? It looks like it doesn't understand the multi-stage build directive "FROM golang:1.10 AS go_builder" that was introduced more than a year ago with Docker 17.05.
Yeah, it's old (the one that comes with CentOS 7):
[vagrant@localhost ~]$ docker --version
Docker version 1.13.1, build dded712/1.13.1
I'll try a newer version. It would be helpful to update the README with the minimum supported version.
That indeed looks pretty old. Everything should be okay with 17.05 or newer, but I haven't tested with it. If a newer version works for you, could you please submit a pull request adding the minimum version to the README? Thanks!
Different problem now, on a recent version of Docker:
[vagrant@localhost api]$ docker --version
Docker version 18.06.1-ce, build e68fc7a
This is the error message:
Generating swift protos...
make[1]: Entering directory `/vagrant/ttn-playground/api'
make[1]: Leaving directory `/vagrant/ttn-playground/api'
mockgen -source=./protocol/lorawan/device.pb.go -package lorawan DeviceManagerClient > protocol/lorawan/device_mock.go
/bin/sh: mockgen: command not found
make: *** [mocks] Error 127
Hmm, mockgen
is a Go tool that isn't really needed if we just want to compile the protos. You could work around this by removing the mocks
dependency from the all
target in the Makefile (currently that's line 9).
Hello, if I execute the "make clean all" command on my Ubuntu 17.10 then after a few minutes I get this message and the setup terminates:
KR Bernd