Custom Query (2297 matches)
Results (40 - 42 of 2297)
Ticket | Resolution | Summary | Owner | Reporter |
---|---|---|---|---|
#1818 | invalid | Custom Error Pages fails to return the correct Content-Type header in its response | ||
Description |
Similar Issue with here: https://github.com/kubernetes/ingress-nginx/issues/4039 Background: I configured a custom error page on Nginx based on the Accept Header. For example: curl -i https://test-nginx.text.com/api/nginxTest/502 --header 'Accept: application/json'. It would return on cli like this: HTTP/1.1 502 Bad Gateway Server: nginx Date: Mon, 22 Jul 2019 00:16:13 GMT Content-Type: application/json Content-Length: 115 Connection: keep-alive ETag: "5d301e25-73" X-Content-Type-Options: nosniff { "result" : "ERROR", "apiErrorCode" : -1, "message" : "Bad gateway", "localizedMessage" : "Bad gateway" } But if I didn't pass any Accept header. The default text/html should handle it. In cli, it shows the HTML error page but when I tried to access it on a browser the HTML error page would not show. In Google Chrome v 75.0.3770.142 : It shows "ERR_INVALID_SIGNED_EXCHANGE" In Safari v 12.1: It would download the page In Mozilla Firefox v63.0.3: It would show the custom XML custom error page The code should return a default content-type header text/html, but when it fails to decode the Accept header, it simply mirrors whatever came from the request into the response. The expected behavior, in this case, is for the default backend use Content-Type: text/html when it fails to decode the Accept header. I already tried adding the add_header X-Content-Type-Options nosniff always, but it did not fix the issue. Snippet custom nginx config: map $http_accept $extension { default html; ~application/json json; ~application/xml xml; more_set_headers 'Content-Type:$http_accept'; } |
|||
#899 | invalid | Response headers in body | ||
Description |
I dont understand why the response headers are in the body with 'proxy_path' option. I woul'd like to use this with OpenWRT 15.05 example : Server: nginx/1.6.2 Date: Thu, 11 Feb 2016 14:02:17 GMT Content-Type: text/plain Content-Length: 6 Last-Modified: Fri, 05 Feb 2016 14:38:29 GMT Connection: close ETag: "56b4b3e5-6" Accept-Ranges: bytes prout I have no problems with the last OpenWRT sources. Any idea ? Thank Adrien |
|||
#1097 | fixed | Nginx worker process exited on signal 11 | ||
Description |
I have 2 nginx frontends worked in load balancing mode. Today, around the same time on both frontends I got error: worker process exited on signal 11 Backtrace for both core dumps are similar. Backtrace are below. #0 0x0000000000000000 in ?? () No symbol table info available. #1 0x0000000000457a37 in ngx_kqueue_process_events (cycle=0x8024b3050, timer=23, flags=1) at src/event/modules/ngx_kqueue_module.c:669 events = 512 n = 85 i = 501 instance = 0 level = 140737488349120 err = 0 ev = (ngx_event_t *) 0x806bd7478 queue = (ngx_queue_t *) 0x4ab0b1 ts = {tv_sec = 0, tv_nsec = 23000000} tp = (struct timespec *) 0x7fffffffe758 #2 0x00000000004482fe in ngx_process_events_and_timers (cycle=0x8024b3050) at src/event/ngx_event.c:242 flags = 1 timer = 23 delta = 1475766275958 #3 0x0000000000455aa3 in ngx_worker_process_cycle (cycle=0x8024b3050, data=0x3) at src/os/unix/ngx_process_cycle.c:753 worker = 3 #4 0x0000000000451d30 in ngx_spawn_process (cycle=0x8024b3050, proc=0x4559d0 <ngx_worker_process_cycle>, data=0x3, name=0x523cd6 "worker process", respawn=-4) at src/os/unix/ngx_process.c:198 on = 1 pid = 0 s = 20 #5 0x0000000000453a29 in ngx_start_worker_processes (cycle=0x8024b3050, n=16, type=-4) at src/os/unix/ngx_process_cycle.c:358 i = 3 ch = {command = 1, pid = 40518, slot = 19, fd = 8} #6 0x00000000004537be in ngx_master_process_cycle (cycle=0x8024b3050) at src/os/unix/ngx_process_cycle.c:243 title = 0x8097e7b9c "\b" p = (u_char *) 0x8097e7bc0 "\020" size = 37 i = 1 n = 140737488349776 sigio = 0 set = {__bits = {0, 0, 0, 0}} itv = {it_interval = {tv_sec = 0, tv_usec = 0}, it_value = {tv_sec = 6, tv_usec = 0}} live = 1 delay = 0 ls = (ngx_listening_t *) 0x0 ccf = (ngx_core_conf_t *) 0x8024b4b58 #7 0x00000000004129f8 in main (argc=1, argv=0x7fffffffed60) at src/core/nginx.c:367 b = (ngx_buf_t *) 0x800745c00 log = (ngx_log_t *) 0x75b648 i = 34386931443 cycle = (ngx_cycle_t *) 0x802483050 init_cycle = {conf_ctx = 0x0, pool = 0x802406800, log = 0x75b648, new_log = {log_level = 0, file = 0x0, connection = 0, disk_full_time = 0, handler = 0, data = 0x0, writer = 0, wdata = 0x0, action = 0x0, next = 0x0}, log_use_stderr = 0, files = 0x0, free_connections = 0x0, free_connection_n = 0, modules = 0x0, modules_n = 0, modules_used = 0, reusable_connections_queue = {prev = 0x0, next = 0x0}, listening = {elts = 0x0, nelts = 0, size = 0, nalloc = 0, pool = 0x0}, paths = {elts = 0x0, nelts = 0, size = 0, nalloc = 0, pool = 0x0}, config_dump = {elts = 0x0, nelts = 0, size = 0, nalloc = 0, pool = 0x0}, open_files = {last = 0x0, part = { elts = 0x0, nelts = 0, next = 0x0}, size = 0, nalloc = 0, pool = 0x0}, shared_memory = {last = 0x0, part = {elts = 0x0, nelts = 0, next = 0x0}, size = 0, nalloc = 0, pool = 0x0}, connection_n = 0, files_n = 0, connections = 0x0, read_events = 0x0, write_events = 0x0, old_cycle = 0x0, conf_file = {len = 31, data = 0x520358 "/usr/local/etc/nginx/nginx.conf"}, conf_param = {len = 0, data = 0x0}, conf_prefix = {len = 21, data = 0x520358 "/usr/local/etc/nginx/nginx.conf"}, prefix = {len = 21, data = 0x520342 "/usr/local/etc/nginx/"}, lock_file = {len = 0, data = 0x0}, hostname = {len = 0, data = 0x0}} cd = (ngx_conf_dump_t *) 0x80076a000 ccf = (ngx_core_conf_t *) 0x802484d08 |