resgateio / resgate

A Realtime API Gateway used with NATS to build REST, real time, and RPC APIs, where all your clients are synchronized seamlessly.
https://resgate.io
MIT License
685 stars 67 forks source link

Installing resgate from source #228

Open jurgisk opened 2 years ago

jurgisk commented 2 years ago

Hi, I'm trying to build a docker image that would dynamically write a configuration and only then start the resgate server. The dynamic bit is picking up the NATS server IP. I'm running the setup in AWS, so just want to run some python scripts to get the details.

The resgate docker image (this one resgateio/resgate:1.7.5-linux) doesn't seem to have any python or even bash or sh installed on it. So I thought - I would have to install the resgate from source. So I started with a different source image (python:3.8-buster) and installed golang. My golang version is (go version go1.13.5 linux/amd64).

So I ran this: go get -u github.com/resgateio/resgate

And the result looks like an error to me: root/go/src/github.com/nats-io/nats.go/nats.go:1888:23: nc.current.url.Redacted undefined (type *url.URL has no field or method Redacted)

Any ideas on how to install it locally? Or maybe there's another way to get /bin/bash and python into the resgateio/resgate:1.7.5-linux docker image?

Many thanks, Jurgis