summaryrefslogtreecommitdiff
path: root/cgi/live-build-cgi.cron
diff options
context:
space:
mode:
authorRichard Nelson <unixabg@gmail.com>2011-12-23 19:58:31 -0600
committerRichard Nelson <unixabg@gmail.com>2011-12-23 19:58:31 -0600
commitf4ee97726cb6957aee97e6ccf3223b5fe2965b05 (patch)
treefc17947c4a0613c46af1401297e2f7365b14aa83 /cgi/live-build-cgi.cron
parentb16617d8c160ea493eb02b3f3c22f054e6e08bcf (diff)
downloadvyos-live-build-f4ee97726cb6957aee97e6ccf3223b5fe2965b05.tar.gz
vyos-live-build-f4ee97726cb6957aee97e6ccf3223b5fe2965b05.zip
l-b.cgi modify old --packages param to become cgipackages.list.chroot
Diffstat (limited to 'cgi/live-build-cgi.cron')
-rwxr-xr-xcgi/live-build-cgi.cron22
1 files changed, 16 insertions, 6 deletions
diff --git a/cgi/live-build-cgi.cron b/cgi/live-build-cgi.cron
index bf91b6a49..9ce8acba6 100755
--- a/cgi/live-build-cgi.cron
+++ b/cgi/live-build-cgi.cron
@@ -66,12 +66,13 @@ then
_BUILD=`awk -F\" '/^_BUILD=/{print $2}' ${_FILE}`
# Pull in the email address
_EMAIL=`awk -F\" '/^_EMAIL=/{print $2}' ${_FILE}`
- # Pull in the remote address, atchitecture, and distribution
+ # Pull in cgipackages for config/package-lists/cgipackages.list.chroot
+ _LB_CGIPACKAGES=`awk -F\" '/^_LB_CGIPACKAGES=/{print $2}' ${_FILE}`
+ # Pull in the remote address, atchitecture, distribution, and package-lists.
_REMOTE_ADDR=`awk -F\" '/^REMOTE_ADDR=/{print $2}' ${_FILE}`
_LB_ARCHITECTURES=`awk -F\" '/^LB_ARCHITECTURES=/{print $2}' ${_FILE}`
_LB_DISTRIBUTION=`awk -F\" '/^LB_DISTRIBUTION=/{print $2}' ${_FILE}`
- _LB_PACKAGE_LISTS=`awk -F\" '/^LB_PACKAGE_LISTS=/{print $2}' ${_FILE}`
- _LB_PACKAGES=`awk -F\" '/^LB_PACKAGES=/{print $2}' ${_FILE}`
+ _LB_PACKAGE_LISTS=`awk -F\" '/^LB_PACKAGE_LISTS=/{print $2}' ${_FILE}`i
# Pull in the custom bootstrap
_CUSTOM_BOOTSTRAP=`awk -F\" '/^_CUSTOM_BOOTSTRAP=/{print $2}' ${_FILE}`
# Pull in the custom binary
@@ -80,7 +81,16 @@ then
# Drop out some build data for information if something goes wrong.
echo "`date +%b\ %d\ %H:%M:%S` ${_HOSTNAME} live-build-cgi: begin web build (${_BUILD})." >> /var/log/live
- # Creating build directory which also creates the config/chroot_sources folder
+ # Creating build directory and the config/package-lists
+ mkdir -p "${_TEMPDIR}"/"${_BUILD}"/config/package-lists
+
+ # The next two tests are for unofficial third party archives
+ if [ -n "${_LB_CGIPACKAGES}" ]
+ then
+ echo "${_LB_CGIPACKAGES}" > "${_TEMPDIR}"/"${_BUILD}"/config/package-lists/cgipackages.list.chroot
+ fi
+
+ # Creating the config/chroot_sources folder
mkdir -p "${_TEMPDIR}"/"${_BUILD}"/config/chroot_sources
# The next two tests are for unofficial third party archives
@@ -114,10 +124,10 @@ then
if [ "${_ERRORCONFIG}" -eq "0" ] && [ "${_ERRORBUILD}" -eq "0" ]
then
_STATUS="maybe-successful"
- echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LB_ARCHITECTURES}/${_LB_DISTRIBUTION}/${_LB_PACKAGE_LISTS}/${_LB_PACKAGES}\" 200 - \"-\" \"\"">>/var/log/live-cgi.builds
+ echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LB_ARCHITECTURES}/${_LB_DISTRIBUTION}/${_LB_PACKAGE_LISTS}/${_LB_CGIPACKAGES}\" 200 - \"-\" \"\"">>/var/log/live-cgi.builds
else
_STATUS="maybe-failed"
- echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LB_ARCHITECTURES}/${_LB_DISTRIBUTION}/${_LB_PACKAGE_LISTS}/${_LB_PACKAGES}\" 404 - \"-\" \"\"">>/var/log/live-cgi.builds
+ echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LB_ARCHITECTURES}/${_LB_DISTRIBUTION}/${_LB_PACKAGE_LISTS}/${_LB_CGIPACKAGES}\" 404 - \"-\" \"\"">>/var/log/live-cgi.builds
fi
sed -e "s/BUILD/${_BUILD}/g" \