webbuild-cgi: add log message for invalid secret; added a check for /var/autoport existence
This commit is contained in:
parent
2ed572f76b
commit
a292621b9c
@ -56,6 +56,9 @@ if [ "$USER" ]; then
|
||||
USER_ENABLED=
|
||||
fi
|
||||
elif [ "${REQUEST:0:7}" != "refresh" ]; then
|
||||
if [ "$SECRET" ]; then
|
||||
echo "webbuild: invalid credentials: REQUEST=${REQUEST} USER=${USER} SECRET=${SECRET}" >&2
|
||||
fi
|
||||
# no "$USER_SECRET" set; require password
|
||||
echo -n "<output><![CDATA[Please enter your password: <input type=password id=password "
|
||||
echo -n "onkeypress=if(checkEnter(event))"
|
||||
@ -370,7 +373,7 @@ if [ "$REQUEST" = "refresh" -o "$REQUEST" = "refreshjobs" ]; then
|
||||
# echo -n "<div align=left class=processes>"
|
||||
u="$(uptime)"
|
||||
f="$(df / -k -h --output=avail,pcent|tail -n1)"
|
||||
fap="$(df /var/autoport/* -k -h --output=avail,pcent|tail -n+2)"
|
||||
[ -z "/var/autoport" ] && fap="$(df /var/autoport/* -k -h --output=avail,pcent|tail -n+2)"
|
||||
[ "$fap" ] && f="$f | ${fap/$'\n'/ | }"
|
||||
b=`ps ax|grep "rpmbuild .*\.spec$"|while read l; do basename "${l/.spec}"; done`
|
||||
echo -n "Load: <b>${u/*: }</b> | Disk: <b>$f</b> | "
|
||||
|
Loading…
Reference in New Issue
Block a user