Edit by browser
This commit is contained in:
parent
6becaeb18e
commit
4cb40026de
19
step2/2.sh
19
step2/2.sh
|
@ -1,20 +1,3 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#/bin/sbin
|
#/bin/sbin
|
||||||
sh /data/workspace/myshixun/step2/wenti.sh > /root/1.log 2>&1 &
|
sh /data/workspace/myshixun/step2/wenti.sh
|
||||||
curl -s http://cip.cc|awk -F '/' '/URL/{print $4}' > /root/2.log 2>&1 &
|
|
||||||
|
|
||||||
a=$(cat /root/1.log)
|
|
||||||
b=$(cat /root/2.log)
|
|
||||||
FIND_FILE="/data/workspace/myshixun/step2/wenti.sh"
|
|
||||||
FIND_STR="ip.cip.cc"
|
|
||||||
if [ "$a" = "$b" ]
|
|
||||||
then
|
|
||||||
if [ `grep -c "$FIND_STR" $FIND_FILE` -ne '0' ];then
|
|
||||||
echo "禁止使用ip.cip.cc"
|
|
||||||
else
|
|
||||||
echo "答案正确"
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo "答案错误"
|
|
||||||
|
|
||||||
fi
|
|
Loading…
Reference in New Issue