In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "how to configure Nginx multiple domain names under windows". The content of the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "how to configure Nginx multi-domain names under windows".
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 dappled to Testbank; location / {index index.html index.htm;}}
4. B_com.conf content under vhost directory:
Server {listen 80; server_name www.b.com; root dappled to Test2; location / {index index.html index.htm;}}
5. Create a new test and test2 directory and a new index.html file under the local disk d disk
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
Thank you for your reading. The above is the content of "how to configure Nginx multiple domain names under windows". After the study of this article, I believe you have a deeper understanding of how to configure Nginx multi-domain names under windows, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
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.