Compiling the LoRa App Server source-code


#21

Yup… I m faccing this issue while doing make build


#22

In that case, please try building using the Docker container first. If that works, you know it is related to your own development environment (outdated tools, packages, …).


#23

Hi,

the code of “migrations_gen.go” generated different.
As shown in the following figure.
The left use “go build cmd/lora-app-server” can not success.
it says "./main.go:217: undefined: migrations.AssetDir
./main.go:475: undefined: static.AssetDir
./main.go:476: undefined: static.AssetInfo
"
But the right one can success.
Does anyone come across this problem?
Thank you!
%E7%94%9F%E6%88%90%E4%BB%A3%E7%A0%81


#24

You should not use go build cmd/lora-app-server, use make build (as documented: https://www.loraserver.io/lora-app-server/community/source/).


#25

Thank you.
I use “make requirements ui-requirements"、“make clean”、“make build”,but not work.
Like this,


#26

Is it a problem with “go-bindata”?


#27

See the fatal error in your logs, that should not be there? Maybe because the lora-app-server directory is not a git clone?


#28

Thank you.
I tried git clone.
But it doesn’t seem to be successful.


#29

Hmm, that is odd. I don’t know what is causing that. Could you try using the provided Docker development container? At least then you have an environment that I can reproduce.

docker-compose run --rm appserver bash

And then the usual commands. All the project files and build artifacts will be shared with the Docker host :slight_smile:


#30

Thank you.
Today it works.
Maybe because the computer was restarted.


#32

thanks brocaar for your work, when i use the Docker development container with
docker-compose run --rm appserver bash
this happened
make requirements
Installing development tools
#github.com/goreleaser/nfpm/deb
../../goreleaser/nfpm/deb/deb.go:150:9: unknown field 'Format' in struct literal of type tar.Header
../../goreleaser/nfpm/deb/deb.go:232:9: unknown field 'Format' in struct literal of type tar.Header
../../goreleaser/nfpm/deb/deb.go:251:9: unknown field 'Format' in struct literal of type tar.Header
../../goreleaser/nfpm/deb/deb.go:268:10: unknown field 'Format' in struct literal of type tar.Header
make: *** [Makefile:74: requirements] Error 2
with version 0.19.0 and 0.18.2 works fine.


#33

Could you try to rebuild the appserver image? (docker-compose build appserver)


#34

Hi guys!

I have compiled the 0.20.1 lora-app-gateway, and when i am trying to join the web interface i saw this:
Capture

When i go on swagger i got the REST Api. But i haven’t the other API :confused:

Thanks!!


#35

This question has been asked before, I think the solution is already mentioned in this topic (I moved your message).


#36

make requirements hangs up and do not respond anything for a long time. Any solution?


#37

If you are using a proxy, don’t forget to set it in the console:

http_proxy=your_proxy_ip:your_proxy_port
https_proxy=your_proxy_ip:your_proxy_port


#38

When i make requirements, i get the following error.
My guess is there is a version mismatch somewhere and am missing it.

$ make requirements
echo “Installing development tools”
Installing development tools
go get -u github-com/golang/lint/golint
go get -u github-com/brocaar/grpc-gateway/protoc-gen-grpc-gateway
github-com/brocaar/grpc-gateway/protoc-gen-grpc-gateway
…/…/…/github-com/brocaar/grpc-gateway/protoc-gen-grpc-gateway/main.go:65:21: not enough arguments in call to gengateway.New
have (“github-com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway/descriptor”.Registry, bool, string)
want (
“github-com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway/descriptor”.Registry, bool, string, string)

Any idea what might be wrong?

Thanks!


#39

Hi, I have the same issue running the command
docker-compose run --rm appserver bash


#40

I’ve experienced the same issue…


#41

Please pull the latest master and try again. It should be solved :slight_smile: