Optic integrates with NGINX as a Lua filter. You need to have the OpenResty lua-nginx-module module installed. If you are using a OpenResty NGINX distribution,
lua-nginx is already installed.
Download the Optic Lua code from github or install it with
luarocks install --server=http://luarocks.org/manifests/optic optic-nginx
nginx.confto include optic-nginx in the servers and locations where you want Optic to observe your traffic.
Be sure to include the correct package path in
lua_package_pathfor the optic plugin. This is normally
/usr/share/lua/5.1when installing with
Reload the NGINX config with
nginx -s reload