summaryrefslogtreecommitdiff
path: root/cgi/live-build-cgi
diff options
context:
space:
mode:
authorRichard Nelson <unixabg@gmail.com>2012-01-16 19:22:47 -0600
committerRichard Nelson <unixabg@gmail.com>2012-01-16 19:22:47 -0600
commitd33c099ede8d64d9a7d72a26930ac109450e7504 (patch)
tree0db1ad34adcb7b385ddc8a79ccffc48b413b571b /cgi/live-build-cgi
parentfe93b0157199a93784478369b0123afae51d4bf3 (diff)
downloadvyos-live-build-d33c099ede8d64d9a7d72a26930ac109450e7504.tar.gz
vyos-live-build-d33c099ede8d64d9a7d72a26930ac109450e7504.zip
l-b.cgi - Add pending build(s) to be processed ahead of your request.
Diffstat (limited to 'cgi/live-build-cgi')
-rwxr-xr-xcgi/live-build-cgi4
1 files changed, 4 insertions, 0 deletions
diff --git a/cgi/live-build-cgi b/cgi/live-build-cgi
index 655418a79..6e8f8b607 100755
--- a/cgi/live-build-cgi
+++ b/cgi/live-build-cgi
@@ -118,11 +118,15 @@ else
# Getting build identifier
_BUILD=$(date +%Y%m%d.%H%M%S.%N)
+ # Getting number of builds pending.
+ _QUEUENUM=$(ls "${_TEMPDIR}"/*.build | wc -l)
+
#echo "${QUERY_STRING}"
# Sending html confirmation
# Note: On each string remember to use a delimeter that is not in the string.
sed -e "s/BUILD/${_BUILD}/g" \
-e "s/EMAIL/${_EMAIL}/" \
+ -e "s/QUEUENUM/${_QUEUENUM}/" \
-e "s/LB_BINARY_IMAGES/${LB_BINARY_IMAGES}/" \
-e "s/LB_DISTRIBUTION/${LB_DISTRIBUTION}/" \
-e "s/LB_PACKAGE_LISTS/${LB_PACKAGE_LISTS}/" \