#!/bin/bash

HOST='news.idcquan.com'
IP_SUFFIX=23
for node in dg xm
do
    PROXY_SER="http://${node}-proxy.ddos.com:56321"
    echo "##### ${node} node request result #####"
    for bk in {1..3}
    do
        if [[ "${node}" = "dg" ]]
        then
            curl -sSfLI -x ${PROXY_SER} -H "Host: ${HOST}" http://172.16.${bk}.${IP_SUFFIX}
        else
            curl -sSfLI -x ${PROXY_SER} -H "Host: ${HOST}" http://172.17.${bk}.${IP_SUFFIX}
        fi
    done
done
read -n1 var
