G
G
glorfindeil2016-09-27 21:29:15
Nginx
glorfindeil, 2016-09-27 21:29:15

How to setup nginx for ssl redirect?

Hello!
There is the following hodgepodge:
The server hangs on the host https://myhost.com
Inside, nginx is configured with a redirect to localhost:5000 where the web application is running. SSL is proxied as it should be.
Inside, nginx is configured with a redirect from localhost:8081 to localhost:8080 where the backend is spinning.
When a request is sent from localhost:5000 to localhost:8081 an error occurs

Mixed Content: The page at 'https://myhost.com/' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://localhost:8081/api/bla This request has been blocked; the content must be served over HTTPS.

How can I make an http request inside the server without raising ssl on the application server 8080?
Thanks in advance.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
G
glorfindeil, 2016-09-29
@glorfindeil

Managed to solve through a third-level domain and an additional proxy through it

E
evnuh, 2016-09-27
@evnuh

Why are you terminating https on the backend and not in nginx?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question