[ERR] Kong cannot find an 'nginx' executable.

1,147 views
Skip to first unread message

aman garg

unread,
Aug 3, 2015, 9:14:30 AM8/3/15
to KONG
Cannot get source files of kong working.

make dev command is not working and then it is giving an error for nginx.

kong start -c kong_DEVELOPMENT.yml
[INFO] Using configuration: kong_DEVELOPMENT.yml
[INFO] Kong version.......0.4.1
       Proxy HTTP port....8000
       Proxy HTTPS port...8443
       Admin API port.....8001
       dnsmasq port.......8053
       Database...........cassandra keepalive=60000 port=9042 timeout=1000 hosts=localhost keyspace=kong_development
[INFO] Connecting to the database...
[ERR] Kong cannot find an 'nginx' executable.
Make sure it is in your $PATH or in one of the following directories:
/usr/local/openresty/nginx/sbin/
/usr/local/opt/openresty/bin/
/usr/local/bin/
/usr/sbin/

Marco

unread,
Aug 3, 2015, 4:00:39 PM8/3/15
to KONG
The easiest way to fix this is:
  • Installing the latest version of Kong from getkong.org using one of the distributions.
  • Also install the following dependencies: wget curl tar make gcc unzip git liblua5.1-0-dev
  • Cloning the repository
  • Running `sudo make dev`.
Let me know if this fixes it.

aman garg

unread,
Aug 4, 2015, 5:43:55 AM8/4/15
to Marco, KONG
Still not working : Sudo make dev command

lua: /usr/local/share/lua/5.1/kong/cli/utils.lua:7: module 'ansicolors' not found:
no field package.preload['ansicolors']
no file './ansicolors.lua'
no file '/usr/local/share/lua/5.1/ansicolors.lua'
no file '/usr/local/share/lua/5.1/ansicolors/init.lua'
no file '/usr/local/lib/lua/5.1/ansicolors.lua'
no file '/usr/local/lib/lua/5.1/ansicolors/init.lua'
no file '/usr/share/lua/5.1/ansicolors.lua'
no file '/usr/share/lua/5.1/ansicolors/init.lua'
no file './ansicolors.so'
no file '/usr/local/lib/lua/5.1/ansicolors.so'
no file '/usr/lib/x86_64-linux-gnu/lua/5.1/ansicolors.so'
no file '/usr/lib/lua/5.1/ansicolors.so'
no file '/usr/local/lib/lua/5.1/loadall.so'
stack traceback:
[C]: in function 'require'
/usr/local/share/lua/5.1/kong/cli/utils.lua:7: in main chunk
[C]: in function 'require'
bin/kong:13: in main chunk
[C]: ?
Makefile:17: recipe for target 'dev' failed
make: *** [dev] Error 1


--
You received this message because you are subscribed to a topic in the Google Groups "KONG" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/konglayer/7P75WpGeh0g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to konglayer+...@googlegroups.com.
To post to this group, send email to kong...@googlegroups.com.
Visit this group at http://groups.google.com/group/konglayer.
To view this discussion on the web visit https://groups.google.com/d/msgid/konglayer/7bfd8dcc-77b2-4ac5-a517-b1fc0e9023cf%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Marco

unread,
Aug 4, 2015, 4:22:58 PM8/4/15
to KONG, ma...@mashape.com
After cloning the repo, and before running "sudo make dev", let's add this one more step:
  • sudo make install
This should force the re-installation of the Luarocks dependencies (which it's weird because they should have been already installed when installing Kong).

aman garg

unread,
Aug 5, 2015, 2:30:05 AM8/5/15
to KONG, ma...@mashape.com
Hi all,

I was configuring kong dev version through this link http://getkong.org/download/#other.


Where do i need to configure lua_package_path

Error Log:

ubuntu@ip-172-31-31-222:~/kong$ sudo kong start
[WARN] No configuration at: /etc/kong/kong.yml using default config instead.
[INFO] Using configuration: /usr/local/lib/luarocks/rocks/kong/0.4.1-1/conf/kong.yml
[INFO] Kong version.......0.4.1
Proxy HTTP port....8000
Proxy HTTPS port...8443
Admin API port.....8001
dnsmasq port.......8053
Database...........cassandra keepalive=60000 port=32966 timeout=2000 hosts=ec2-52-7-33-160.compute-1.amazonaws.com keyspace=kong
[INFO] Connecting to the database...
[INFO] dnsmasq stopped
[INFO] dnsmasq started (dnsmasq)
[WARN] ulimit is currently set to "1024". For better performance set it to at least "4096" using "ulimit -n"
nginx: [emerg] unknown directive "ssl_certificate_by_lua" in /usr/local/kong/nginx.conf:76
[INFO] dnsmasq stopped
[ERR] Could not start Kong

Marco

unread,
Aug 6, 2015, 3:06:18 PM8/6/15
to KONG, ma...@mashape.com
That problem happens because you need to apply a patch to nginx to support the "ssl_certificate_by_lua" instruction.

The quickest way to fix this is to install Kong normally as you would do in production using one of the packages available at http://getkong.org/download/, and then execute the new instructions I told you before.

Let me know if that works

aman garg

unread,
Aug 7, 2015, 4:10:22 AM8/7/15
to Marco, KONG
Yeah...it worked.

@Marco : appreciate your help and time.

As we are using the kong api manager according to our requirements and building over it for new functions, I have a couple of questions :

1. How should we start with the development of new functions, like is there a documentation of kong code in github ?
2. To resolve anything regarding kong and openresty, what community can give us a quick and right response ?


Thanks
Aman



Ahmad Nassri

unread,
Aug 7, 2015, 7:38:38 PM8/7/15
to aman garg, Marco, KONG
hey Aman,

we can help you debug this in real-time if you join our gitter chat https://gitter.im/Mashape/kong (we're usually online between 10 AM - 6 PM PST)

hopefully it would be faster than emails :)

You received this message because you are subscribed to the Google Groups "KONG" group.
To unsubscribe from this group and stop receiving emails from it, send an email to konglayer+...@googlegroups.com.

To post to this group, send email to kong...@googlegroups.com.
Visit this group at http://groups.google.com/group/konglayer.

For more options, visit https://groups.google.com/d/optout.
--


---
Ahmad Nassri

Augusto Marietti

unread,
Aug 10, 2015, 1:31:46 AM8/10/15
to KONG, ma...@mashape.com
Hi Aman,

1. as Ahmad said, for general community support you can find us on Gitter, but for specific things like this, we dont have a documentation out yet, this is part of our official support plans from our core engineers, you can inquiry here: https://getkong.org/enterprise/

2. regarding kong is here for community based, for OpenResty instead is: https://groups.google.com/forum/#!forum/openresty-en


Hope it helps
aghi

On Tuesday, August 4, 2015 at 11:30:05 PM UTC-7, aman garg wrote:
Reply all
Reply to author
Forward
0 new messages