mirror of
https://github.com/fatedier/frp.git
synced 2026-01-11 22:23:12 +00:00
Merge pull request #968 from fatedier/health
support health check and code refactor
This commit is contained in:
@@ -25,7 +25,7 @@ token = 12345678
|
||||
admin_addr = 127.0.0.1
|
||||
admin_port = 7400
|
||||
admin_user = admin
|
||||
admin_passwd = admin
|
||||
admin_pwd = admin
|
||||
|
||||
# connections will be established in advance, default value is zero
|
||||
pool_count = 5
|
||||
@@ -73,6 +73,10 @@ remote_port = 6001
|
||||
group = test_group
|
||||
# group should have same group key
|
||||
group_key = 123456
|
||||
# enable health check for the backend service, it support 'tcp' and 'http' now
|
||||
# frpc will connect local service's port to detect it's healthy status
|
||||
health_check_type = tcp
|
||||
health_check_interval_s = 10
|
||||
|
||||
[ssh_random]
|
||||
type = tcp
|
||||
@@ -126,6 +130,11 @@ locations = /,/pic
|
||||
host_header_rewrite = example.com
|
||||
# params with prefix "header_" will be used to update http request headers
|
||||
header_X-From-Where = frp
|
||||
health_check_type = http
|
||||
# frpc will send a GET http request '/status' to local http service
|
||||
# http service is alive when it return 2xx http response code
|
||||
health_check_url = /status
|
||||
health_check_interval_s = 10
|
||||
|
||||
[web02]
|
||||
type = https
|
||||
|
||||
Reference in New Issue
Block a user