Skip to content

Instantly share code, notes, and snippets.

@bash99
Created October 26, 2017 12:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bash99/ff3eaf25cbba55d54af74b0f4cbaf560 to your computer and use it in GitHub Desktop.
Save bash99/ff3eaf25cbba55d54af74b0f4cbaf560 to your computer and use it in GitHub Desktop.
haproxy cfg for http_proxy check
global
log /dev/log local0
log /dev/log local1 notice
chroot /var/lib/haproxy
stats socket /run/haproxy/admin.sock.3001 mode 660 level admin
stats timeout 30s
user haproxy
group haproxy
daemon
# Default SSL material locations
ca-base /etc/ssl/certs
crt-base /etc/ssl/private
# Default ciphers to use on SSL-enabled listening sockets.
# For more information, see ciphers(1SSL). This list is from:
# https://hynek.me/articles/hardening-your-web-servers-ssl-ciphers/
ssl-default-bind-ciphers ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!aNULL:!MD5:!DSS
ssl-default-bind-options no-sslv3
defaults
mode tcp
log global
option dontlognull
timeout check 30s
maxconn 2000
# This server group is used for final users.
# Each server should point at one foreign Internet address
# http proxy is accept
listen v2ray_http
bind 127.0.0.1:3001
mode tcp
option tcp-check
tcp-check send GET\ http://google.com/generate_204\ HTTP/1.0\r\n
tcp-check send Host:\ google.com\r\n
tcp-check send User-Agent:\ curl/7.52.1\r\n
tcp-check send Accept:\ */*\r\n
tcp-check send \r\n
tcp-check expect rstring ^HTTP/1.1\ 204
balance leastconn
timeout server 600000
timeout client 600000
timeout connect 3000
server alpharack-v2ray 127.0.0.1:31771 check inter 15s downinter 1m fall 4 weight 10
server virmatch-v2ray 127.0.0.1:7788 check inter 15s downinter 1m fall 4 weight 10
listen monitor_mgmt
mode http
bind 0.0.0.0:3390
stats enable
stats admin if TRUE
stats uri /
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment