We have 2 IIS servers with multiple websites on them. I want to check for each website if the are still running on each server. If i do a simple port check the IIS will reply even when 19 of the 20 sites are down. So this doesn't really help me.
I have this curl that does what i want but i have no idea how to place this in HAProxy and even if it's possible.
curl --connect-to 'website':443:'internalserverip':443 'https://website' -k
The curl commands works without the ''
tcp check is what i am using now but that sin't enough.
global
log /dev/log local0
log 127.0.0.1 local1 notice
maxconn 4096
user haproxy
group haproxy
daemon
defaults
log global
mode tcp
option dontlognull
retries 3
option redispatch
maxconn 2000
contimeout 5000
clitimeout 50000
srvtimeout 50000
frontend 10_20_1_129_443
bind 10.20.1.129:443
option tcplog
option logasap
mode tcp
default_backend 10_20_1_129_nodes_443
backend 10_20_1_129_nodes_443
mode tcp
balance roundrobin
option log-health-checks
server web01 10.20.1.50:443 check
server web02 10.20.1.128:443 check
frontend 10_20_1_129_80
bind 10.20.1.129:80
option tcplog
option logasap
mode tcp
default_backend 10_20_1_129_nodes_80
backend 10_20_1_129_nodes_80
mode tcp
balance roundrobin
option log-health-checks
server web01 10.20.1.50:80 check
server web02 10.20.1.128:80 check