In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
This article gives you an example to share a simple Nginx multi-domain name configuration tutorial for your reference. The details are as follows.
1. The directory structure for installing nginx under windows is as follows:
two。 Conf/nginx.conf content in the nginx-1.12.1 directory
# user nobody;worker_processes 1 vhost/*.conf; events {worker_connections 1024;} http {include mime.types; default_type application/octet-stream; sendfile on; keepalive_timeout 65; server {listen 80 default_server; server_name localhost default_server; root html; location / {index index.html index.htm;}} include.. / vhost/*.conf;}
3. A_com.conf content under vhost directory:
Server {listen 80; server_name www.a.com; root DGV server_name www.a.com; root TestAccord; location / {Testi}}
4. B_com.conf content under vhost directory:
Server {listen 80; server_name www.b.com; root DVUR to Test2; location / {index index.html index.htm;}}
5. Create a new test and test2 directory under the local disk D, and create a new index.html file
6. Modify the hosts under C:\ Windows\ System32\ drivers\ etc on the local disk C as follows
127.0.0.1 www.a.com127.0.0.1 www.b.com
7. Use cmd to enter the nginx installation directory to execute
Nginx.exe start
Nginx-t / / check syntax
Nginx-s reload / / restart
Nginx-s stop / / stop
8. Open the browser and enter the URL
Github warehouse: https://github.com/chengzao
The above is the whole content of this article, I hope it will be helpful to your study, and I also hope that you will support it.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.