V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
NGINX
NGINX Trac
3rd Party Modules
Security Advisories
CHANGES
OpenResty
ngx_lua
Tengine
在线学习资源
NGINX 开发从入门到精通
NGINX Modules
ngx_echo
wobuhuicode
V2EX  ›  NGINX

nginx 配置的一些疑惑

  •  
  •   wobuhuicode · 2016-11-09 16:23:52 +08:00 · 2681 次点击
    这是一个创建于 2717 天前的主题,其中的信息可能已经有所发展或是发生改变。

    手上的网站使用 nginx 去监听 80 端口,访问 3000/3001 两个端口。那么我想禁止—域名:端口的访问模式,这个时候应该在 nginx 去把 3000 端口返回 403 还是使用 iptables 去关闭端口 呢?

    3 条回复    2016-11-09 16:46:57 +08:00
    234747005
        1
    234747005  
       2016-11-09 16:33:48 +08:00
    反向代理即可
    stamaimer
        2
    stamaimer  
       2016-11-09 16:36:41 +08:00 via iPhone   ❤️ 1
    3000/3001 监听本地请求, nginx 把 80 端口的请求转到 3000/3001
    wobuhuicode
        3
    wobuhuicode  
    OP
       2016-11-09 16:46:57 +08:00
    @stamaimer 明白了~自己想歪了~
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3383 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 00:40 · PVG 08:40 · LAX 17:40 · JFK 20:40
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.