tarantool / nginx_upstream_module

Tarantool NginX upstream module (REST, JSON API, websockets, load balancing)
Other
174 stars 18 forks source link

Makefile unclear about dependancies #122

Open DarkWiiPlayer opened 5 years ago

DarkWiiPlayer commented 5 years ago

I just spent about 30 minutes figuring out how to add this module to nginx, and it seems the fix was that I needed to make yajl and make msgpack within the module directory before compiling nginx/openresty.

The readme does mention that these are needed; however it does not tell you that they aren't actually being built, causing an error, and you have to build them manually.

I find this quite unintuitive and believe that the readme should mention this to spare future users having to find it out for themselves.

Currently my installation process looks about like this:

# download and unpack latest openresty source
git clone https://github.com/tarantool/nginx_upstream_module.git tarantool_upstream --recursive

# Nobody told me this was necessary :'(
cd tarantool_upstream
make -j `nproc` yajl && make -j `nproc` msgpack || exit
cd ../

./configure --add-module=tarantool_upstream
make
# add some more files, cleanup, etc.
dedok commented 5 years ago

Hi,

thank you for the feedback.

Makefile uses for developing, testing. So if you with to have NGINX with this module installed, then you have to use add-module. But, this module also requires to have installed libyajl-dev and msgpack-dev for installing extra packages you could use yum, dep, etc.

Probably, you have some ideas to make it better, feel free to share it.

Thanks!