Compare commits

..

No commits in common. "c5f8f189cc17eae99ced62a92c26c8dfdda29ae1" and "e6808e1dbd37aae884f4facbc41b3b1f2334b75b" have entirely different histories.

2 changed files with 9 additions and 20 deletions

View File

@ -14,15 +14,15 @@ app_domain = "https://twin.batiao8.com"
ingore_event = "/api/user/event" ingore_event = "/api/user/event"
[mysql] [mysql]
host = "10.7.0.36" host = "10.0.2.157"
port = 3308 port = 3307
user = "twin" user = "twin"
pass = "z[T)5svx--N(nUO(" pass = "z[T)5svx--N(nUO("
db = "twin" db = "twin"
threshold = 10000 threshold = 10000
[elastic] [elastic]
address = "http://10.7.0.36:9200" address = "http://10.0.2.133:9200"
username = "elastic" username = "elastic"
password = "o2NJzeAODwpfAgLJ5SFY" password = "o2NJzeAODwpfAgLJ5SFY"
@ -52,7 +52,7 @@ qy_kf_id = ""
[metric] [metric]
address = "http://10.7.0.36:8086" address = "http://10.0.2.157:8086"
username = "batiao" username = "batiao"
password = "Batiao12B" password = "Batiao12B"

View File

@ -1,18 +1,5 @@
#!/bin/bash #!/bin/bash
set -x
crash() {
SERVICE_NAME="$_SERVICE_NAME"
HOSTNAME_="${_POD_NAME:-$(hostname)}"
IP="$_POD_IP"
curl -sS -G "https://t.batiao8.com/ext/service/crash" \
--connect-timeout 3 --max-time 5 \
--retry 2 --retry-delay 1 \
--data-urlencode "service=$SERVICE_NAME" \
--data-urlencode "hostname=$HOSTNAME_" \
--data-urlencode "ip=$IP" \
>/dev/null 2>&1 || true
}
ROOT=$(cd `dirname $0`; pwd) ROOT=$(cd `dirname $0`; pwd)
cd $ROOT cd $ROOT
@ -22,6 +9,8 @@ fi
while [ true ];do while [ true ];do
$ROOT/bin/$BINARY $@ >> log/run.log 2>&1 $ROOT/bin/$BINARY $@ >> log/run.log 2>&1
crash /usr/local/bin/sendproxy weixin "jiangyong,ranzhenghua" "[$HOSTNAME] [$CONFIG_ENV] [$BINARY] 服务崩溃[`date +"%Y-%m-%d %H:%M:%S"`]"
sleep 10 sleep 10
done done