Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

overriding proxy_access_log with different log_format no longer works in Kong 3.5.0 #12061

Closed
1 task done
reneeckstein opened this issue Nov 20, 2023 · 9 comments · Fixed by #12073
Closed
1 task done
Labels

Comments

@reneeckstein
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Kong version ($ kong version)

Kong 3.5.0

Current Behavior

We use a custom access log format since years with Kong by adding a custom-nginx.conf and include it via KONG_NGINX_HTTP_INCLUDE env var
If we start Kong 3.5.0 with the environment variable KONG_PROXY_ACCESS_LOG set to /dev/stdout custom_proxy_format Kong fails to start.

Error: could not prepare Kong prefix at /usr/local/kong: nginx configuration is invalid (exit code 1):
nginx: [warn] the "user" directive makes sense only if the master process runs with super-user privileges, ignored in /usr/local/kong/nginx.conf:7
nginx: [emerg] invalid parameter "kong_log_format" in /usr/local/kong/nginx-kong.conf:89
nginx: configuration file /usr/local/kong/nginx.conf test failed


  Run with --v (verbose) or --vv (debug) for more details

This happens due to this changed line in Kong release 3.5.0
6890007#diff-d2fc92c2f1cd1ea7d01c13c68b069cbe9927088d2040d5c096906a93cf95bbc5R88

Expected Behavior

same behavior as previous Kong versions.

Steps To Reproduce

No response

Anything else?

No response

@outsinre
Copy link
Contributor

outsinre commented Nov 21, 2023

@reneeckstein We have an internal ticket investigating this issue. Will keep you updated.

Kong introduces a feature to log a kong_request_id in the log to trace the request, and so use a custom log format.

Before a final solution, could you try export KONG_NGINX_PROXY_ACCESS_LOG='/dev/stdout custom_proxy_format'? The side effect is, every request will have two log entries, one to /dev/stdout, another to logs/access.log.

@AnmolSidhu16
Copy link

@outsinre can you help know when are we planning to release this in kong version 3.5.0.

@outsinre
Copy link
Contributor

@AnmolSidhu16 checking with team. Will come back shortly.

@outsinre
Copy link
Contributor

@AnmolSidhu16 it will be released in 3.6.0.0 and also in next minor release of 3.5.

@AnmolSidhu16
Copy link

AnmolSidhu16 commented Dec 28, 2023

@outsinre any timeline around the minor release of 3.5 or 3.6.0.0??

@alexanderccc
Copy link

Also waiting for this to be released, any eta on when it might happen?

@cello86
Copy link

cello86 commented Jan 8, 2024

@alexanderccc I tried 3.5.0.2 and it worked fine.

@alexanderccc
Copy link

Looking for an official container release 😬 as the kic deployment is still broken with custom logging set on the gateway

@balait4
Copy link

balait4 commented Jan 30, 2024

When 3.6.0 will be released, we are also facing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants