I’m running Kong 0.12.1 in Kubernetes and I noticed the Docker overlay was filling up on one of the k8s nodes. I had set the KONG_PROXY_*_LOG environment variables to redirect to /dev/stdout and /dev/stderr, however our node’s disk usage was climbing wherever Kong was deployed.
After some sleuthing, I found Kong was redirecting stdout and stderr to /tmp/lua_*:
root@b2e3372dddc0 /]# ps aux
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 42 0.0 0.0 11644 2672 ? S 19:14 0:00 sh -c /usr/local/openresty/nginx/sbin/nginx -p
/usr/local/kong -c nginx.conf > /tmp/lua_soLvsa 2> /tmp/lua_ujogNz
root 1 0.0 0.2 45292 8640 ? Ss 19:14 0:00 perl /usr/local/openresty/bin/resty /usr/local/bin/kong start --run-migrations --vv
root 7 0.0 0.2 51824 10712 ? S 19:14 0:00 /usr/local/openresty/bin/../nginx/sbin/nginx -p /tmp/tQ2teKlN0L/ -c conf/nginx.conf
root 43 0.0 0.3 220836 12860 ? S 19:14 0:00 nginx: master process
/usr/local/openresty/nginx/sbin/nginx -p /usr/local/kong -c nginx.conf
nobody 50 0.0 0.7 240760 29872 ? S 19:14 0:00 nginx: worker process
nobody 51 0.0 0.7 240632 29632 ? S 19:14 0:00 nginx: worker process
nobody 52 0.0 0.7 240632 29800 ? S 19:14 0:00 nginx: worker process
nobody 53 0.0 0.7 240632 29564 ? S 19:14 0:00 nginx: worker process
Specifically:
sh -c /usr/local/openresty/nginx/sbin/nginx -p
/usr/local/kong -c nginx.conf > /tmp/lua_soLvsa 2> /tmp/lua_ujogNz
Is it possible to disable those redirects? I couldn’t find them in the CMD in the Dockerfile or in the docker-entrypoint.sh.
Thanks!