How to set up nginx to allow HTTP on LAN, and redi

2019-07-16 05:49发布

I'm trying to setup Nginx for some personal web services I have running on my home server.

The network is setup with router between the server and the internet, the router has a Dynamic DNS service running such that I can connect to it while not at home.

I would like Nginx to handle connections from the local network such that it will serve the web services over HTTP and HTTPS without any authentication.

Connections from outside the local network, should redirected to HTTPS for security, and should also be required to authenticate.

The available web services are the same in the both cases. Connections directly to the IP should also be handled in the same way. I already have the web services running over HTTP, so this question is only about how to setup my server blocks

Is this possible?

标签: nginx
0条回答
登录 后发表回答