---
title: "[nginx]域名设置"
author: "MyEyeOfJava"
date: "2012-10-22T15:44:24Z"
tags: []
categories: ["互联网"]
slug: "nginx"
draft: false
lastmod: "2012-10-22T15:44:24Z"
id: 1703059
url: "https://myeyeofjava.iteye.com/blog/1703059"
---

nginx配置文件内include XXXX.conf
xxxx.conf文件内容

```java


server{
        listen          80;
        server_name     dianxinhao123.com;
        location / {
        proxy_pass http://localhost:9875;
        }

}
```



设置后即可生效，但是域名必须要有内网OP的支持，内网用户访问该域名才可以转发到这台机器上