V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
• 请不要在回答技术问题时复制粘贴 AI 生成的内容
tenstone
V2EX  ›  程序员

openresty 能不能通过 lua 实现动态 vhost

  •  
  •   tenstone · Feb 5, 2020 · 2673 views
    This topic created in 2281 days ago, the information mentioned may be changed or developed.
    6 replies    2020-02-06 19:40:18 +08:00
    lp7631010
        1
    lp7631010  
       Feb 5, 2020 via iPhone
    Nginx 都可以 判断 host
    dndx
        2
    dndx  
       Feb 5, 2020
    可以,判断 host + balancer,想怎么代理就怎么代理。
    wangyzj
        3
    wangyzj  
       Feb 5, 2020
    可以
    owenliang
        4
    owenliang  
       Feb 5, 2020
    那就是一个默认的 access 入口,自己做逻辑。

    不知道你的动态是啥意思,kong 可以通过数据库配置 vhost,不需要去开发任何代码。
    holinhot
        5
    holinhot  
       Feb 6, 2020
    cdn 厂商应该都是存数据定时推到 nginx 内存里吧
    holinhot
        6
    holinhot  
       Feb 6, 2020
    动态 vhost 是完全可以。动态 Location 好像无解
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3458 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 49ms · UTC 10:53 · PVG 18:53 · LAX 03:53 · JFK 06:53
    ♥ Do have faith in what you're doing.