Welcome! Log In Create A New Profile

Advanced

Re: Nginx - API Gateway is not forwarding the request to Auth Service

April 11, 2017 03:51AM
Hi maxim,

After implementing your valuable inputs I came across the following error in my application.
Error: "Request 'GET /login' doesn't match 'POST /login"

this means that nginx is sending GET requests to authentication service.

So the flow is as follows and is according to your valuable feedback.

1. I typed the nginx URL in browser "http://localhost:8180/api"
2. NGINX forwarded the request to "http://localhost:8080/login"
3. I get the above error in my auth service i.e "Request 'GET /login' doesn't match 'POST /login"

This forwarded request to auth service should be a POST login

Alternatively,
if I type "http://localhost:8180/login", which is also a NGINX location, I am able to see login page of my auth service.

I want the same for other nginx locaitons i.e. if the request is not authenticated show login page of auth service. get the user authenticated and then forward the requests to upstream server.
Subject Author Posted

Nginx - API Gateway is not forwarding the request to Auth Service

zaidahmd April 10, 2017 04:42AM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

Maxim Dounin April 10, 2017 08:14AM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

zaidahmd April 11, 2017 02:04AM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

zaidahmd April 11, 2017 03:51AM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

Francis Daly April 11, 2017 07:50AM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

zaidahmd April 12, 2017 05:50AM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

Francis Daly April 12, 2017 05:46PM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

zaidahmd April 13, 2017 01:00AM

Re: Nginx - API Gateway is not forwarding the request to Auth Service

Francis Daly April 13, 2017 07:36PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 287
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready