Commit df3d854a by Fred Smith

clean up formatting, pass authentication as cookie

parent 67f8f2c8
......@@ -40,7 +40,7 @@ function checkurl {
CACHEFILE=$(echo $URL | sed -e 's/\//-/g' -e 's/\://g');
echo "<div class=\"col-sm-4\">" >> $WEBOUTPUTFILE
curl -b cookies.txt -m 2 -sL -w "%{http_code} %{time_total}\n" -u $CREDENTIALS $URL -o /dev/null | while read RESPONSECODE TIME; do
curl -m 2 -sL -w "%{http_code} %{time_total}\n" -H "Cookie: $CREDENTIALS" $URL -o /dev/null | while read RESPONSECODE TIME; do
if [[ $RESPONSECODE -lt "500" ]]; then
echo "<div class=\"panel panel-default\">" >> $WEBOUTPUTFILE
else
......@@ -66,8 +66,8 @@ function checkurl {
mv $CACHEDIR/time/$CACHEFILE.new $CACHEDIR/time/$CACHEFILE;
TIMING=$(cat $CACHEDIR/time/$CACHEFILE | singleline ,);
echo "<span class=\"inlinesparkline\">$TIMING</span>" >> $WEBOUTPUTFILE;
echo "$TIME sec</div></div>" >> $WEBOUTPUTFILE
echo "<br /><span class=\"inlinesparkline\">$TIMING</span>" >> $WEBOUTPUTFILE;
echo "<br />$TIME sec</div></div>" >> $WEBOUTPUTFILE
echo "</div>" >> $WEBOUTPUTFILE
if [[ -f $CACHEDIR/$CACHEFILE ]]; then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment