Questions tagged [nginx-njs]

5 questions
2
votes
0 answers

How to use Nginx NJS with native nodejs modules and webpack?

There is a guide https://nginx.org/en/docs/njs/node_modules.html guide that describes how to use 'native' nodejs modules with njs. I followed the guide until I did not understand what it means in bold: Note that in this example generated code is…
Dan B
  • 21
  • 4
1
vote
2 answers

Javascript Regular Expression with multiple conditions

I am using Nginx njs module for some url modifications. My use case is to return the redirection uri for the given uri. URI's will be as follows: /books /books/economic-genious /books/flight-mechanics My regular expression to match the above URI's…
Awesome
  • 5,689
  • 8
  • 33
  • 58
0
votes
0 answers

shared lib fails to load at nginx docker

We used this dockerfile out of this link - https://github.com/nginxinc/docker-nginx/blob/master/mainline/alpine/Dockerfile And included to install this extra module - nginx-mod-http-lua and docker image was built successfully, We confirm that…
Hare Krshn
  • 41
  • 4
0
votes
1 answer

`nginx` reverse proxy issue in `docker`

Map the 80 port of nginx using the port running nginx, docker 11111 nginx is configured as follows user nginx; worker_processes 1; error_log /var/log/nginx/error.log warn; pid /var/run/nginx.pid; events { worker_connections …
陈少锋
  • 1
  • 3
0
votes
1 answer

nginx - njs - ngx_http_auth_request_module how to return 302 to user?

I am using njs ngx_http_auth_request_module. I have js function like this; function introspectAccessToken(r) { r.subrequest("/_oauth2_send_request", function(reply) { if (reply.status == 200) { r.return(204);…
denizg
  • 828
  • 9
  • 18