xiaopanzi
V2EX  ›  软件

不绑定域名的情况下, frp 如何穿透多个 Web 服务?

  •  
  •   xiaopanzi · Dec 1, 2023 · 1262 views
    This topic created in 912 days ago, the information mentioned may be changed or developed.

    我在公网上搭建了一个 frps ,假设 IP 地址是 118.118.118.118 ,其中vhostHTTPPort是 8080 。

    然后我在 frpc 配置了一个 Web 服务:

    [[proxies]]
    name = "web"
    type = "http"
    localIP = "127.0.0.1"
    localPort = 8000
    customDomains = ["118.118.118.118"]
    

    这时候能够通过118.118.118.118:8080直接访问。我想在本地再搭建另外一个 Web 服务,使用不同的本地端口。那么应该如何配置 frp 呢?

    6 replies    2023-12-01 14:30:31 +08:00
    565656
        1
    565656  
       Dec 1, 2023
    chatgpt 都知道
    Yuhyeong
        2
    Yuhyeong  
       Dec 1, 2023
    百度都知道
    totoro625
        3
    totoro625  
       Dec 1, 2023
    不绑定域名、不共用端口的情况下,穿透 type 直接用 tcp 即可,多复制几个[[proxies]]字段,就可以多穿透几个 web 界面了
    totoro625
        4
    totoro625  
       Dec 1, 2023
    如果第二个 web 也想走 vhostHTTPPort 是 8080 ,就必须绑定域名了
    ihainan
        5
    ihainan  
       Dec 1, 2023
    type 选择 tcp
    fengci
        6
    fengci  
       Dec 1, 2023
    反向代理。nginx 或者 这类的软件都可以
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2847 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 39ms · UTC 08:00 · PVG 16:00 · LAX 01:00 · JFK 04:00
    ♥ Do have faith in what you're doing.