Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

客户端多个http服务代理到服务端不同端口中 #3854

Closed
11 tasks
cccqcccq opened this issue Dec 16, 2023 · 2 comments
Closed
11 tasks

客户端多个http服务代理到服务端不同端口中 #3854

cccqcccq opened this issue Dec 16, 2023 · 2 comments

Comments

@cccqcccq
Copy link

cccqcccq commented Dec 16, 2023

Describe the feature request

frpc

serverAddr = "1.1.1.1" #假设我的ip
serverPort = 7000

[[proxies]
name = "web"
type = "http" 
localPort = 3333
customDomains = ["1.1.1.1"] 

[[proxies]] 
name = "web2"
type = "http"
localPort = 5555

frps

bindPort = 7000
#vhostHTTPSPort = 443
vhostHTTPPort = 3333

我想实现将我本地两个http服务代理到公网中
我应该怎么实现访问1.1.1.1:3333时访问本地3333端口的服务
访问1.1.1.1:5555时访问本地5555端口的服务
目前3333端口可以使用,请教这有实现的可能吗,我尝试过在web2中添加以下方法
customDomains = ["1.1.1.1:5555"]
remotePort = 5555
但是都无法正常访问服务

Describe alternatives you've considered

No response

Affected area

  • Docs
  • Installation
  • Performance and Scalability
  • Security
  • User Experience
  • Test and Release
  • Developer Infrastructure
  • Client Plugin
  • Server Plugin
  • Extensions
  • Others
@superzjg
Copy link

type = "http" 换成 type = "tcp", 删除 customDomains,分别配置不同的 remotePort,然后frps防火墙开启对应的端口。

@cccqcccq
Copy link
Author

superzjg

感谢!我会尝试的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants