From: "Liam McLoughlin" <hexxeh@hexxeh.net>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/gentoaster:webui commit in: /, configs/
Date: Tue, 2 Aug 2011 16:48:50 +0000 (UTC) [thread overview]
Message-ID: <c80e652a6becc61fa29e8ae5f2a8c8b5c9ee3771.hexxeh@gentoo> (raw)
commit: c80e652a6becc61fa29e8ae5f2a8c8b5c9ee3771
Author: Liam McLoughlin <hexxeh <AT> hexxeh <DOT> net>
AuthorDate: Tue Aug 2 16:48:28 2011 +0000
Commit: Liam McLoughlin <hexxeh <AT> hexxeh <DOT> net>
CommitDate: Tue Aug 2 16:48:28 2011 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/gentoaster.git;a=commit;h=c80e652a
Keyboard layout support for build tool, Stage3/Portage/BINHOST override from config files
---
configs/fluxbox.ini | 1 +
configs/minimal.ini | 1 +
configs/xfce.ini | 1 +
create_image.sh | 38 +++++++++++++++++++++++++-------------
daemon.php | 2 +-
5 files changed, 29 insertions(+), 14 deletions(-)
diff --git a/configs/fluxbox.ini b/configs/fluxbox.ini
index f199237..cf9c3cb 100644
--- a/configs/fluxbox.ini
+++ b/configs/fluxbox.ini
@@ -5,6 +5,7 @@ BOOT_MEGABYTES='64'
SWAP_MEGABYTES='128'
ROOT_MEGABYTES='7999'
TIMEZONE='Europe/London'
+KEYBOARD='uk'
HOSTNAME='gentoo'
ROOT_PASSWORD='g3nt00'
DEFAULT_USERNAME='gentoo'
diff --git a/configs/minimal.ini b/configs/minimal.ini
index 0d7eed6..13740a2 100644
--- a/configs/minimal.ini
+++ b/configs/minimal.ini
@@ -5,6 +5,7 @@ BOOT_MEGABYTES='64'
SWAP_MEGABYTES='128'
ROOT_MEGABYTES='3903'
TIMEZONE='Europe/London'
+KEYBOARD='uk'
HOSTNAME='gentoo'
ROOT_PASSWORD='g3nt00'
DEFAULT_USERNAME='gentoo'
diff --git a/configs/xfce.ini b/configs/xfce.ini
index 6c249ee..bb4c14f 100644
--- a/configs/xfce.ini
+++ b/configs/xfce.ini
@@ -5,6 +5,7 @@ BOOT_MEGABYTES='64'
SWAP_MEGABYTES='128'
ROOT_MEGABYTES='16190'
TIMEZONE='Europe/London'
+KEYBOARD='uk'
HOSTNAME='gentoo'
ROOT_PASSWORD='g3nt00'
DEFAULT_USERNAME='gentoo'
diff --git a/create_image.sh b/create_image.sh
index 2da2d6f..3858dac 100755
--- a/create_image.sh
+++ b/create_image.sh
@@ -52,11 +52,20 @@ LOG_FILE="${IMAGE_WORK_PATH}/log.txt"
TOOL_RES_PATH=${RUNNING_DIRECTORY}/res
NUM_JOBS=$(( `grep -c processor /proc/cpuinfo`+1 ))
-STAGE3_URL="http://distribution.hexxeh.net/gentoo/stage3-i686-latest.tar.bz2"
-PORTAGE_URL="http://distribution.hexxeh.net/gentoo/portage-latest.tar.bz2"
-BINHOST_URL="http://tinderbox.dev.gentoo.org/default-linux/x86"
EMERGE_PROXY="${FLAGS_proxy}"
+if [ -z ${STAGE3_URL} ]; then
+ STAGE3_URL="http://distribution.hexxeh.net/gentoo/stage3-i686-latest.tar.bz2"
+fi
+
+if [ -z ${PORTAGE_URL} ]; then
+ PORTAGE_URL="http://distribution.hexxeh.net/gentoo/portage-latest.tar.bz2"
+fi
+
+if [ -z ${BINHOST_URL} ]; then
+ BINHOST_URL="http://tinderbox.dev.gentoo.org/default-linux/x86"
+fi
+
# Clean up old mounts
cleanup_mounts() {
sleep 2
@@ -191,19 +200,22 @@ linux32 chroot . /bin/bash /etc/profile &>> ${LOG_FILE}
echo "Step 13: Setting timezone to ${TIMEZONE}"
linux32 chroot . cp /usr/share/zoneinfo/${TIMEZONE} /etc/localtime &>> ${LOG_FILE}
-echo "Step 14: Setting hostname to ${HOSTNAME}"
+echo "Step 14: Setting keyboard layout to ${KEYBOARD}"
+linux32 chroot . sed -i -e "s/keymap=.*/keymap=\"${KEYBOARD}\"/" /etc/conf.d/keymaps &>> ${LOG_FILE}
+
+echo "Step 15: Setting hostname to ${HOSTNAME}"
linux32 chroot . /bin/bash -c "echo hostname='${HOSTNAME}' > /etc/conf.d/hostname" &>> ${LOG_FILE}
linux32 chroot . /bin/bash -c "echo 127.0.0.1 ${HOSTNAME}.local ${HOSTNAME} localhost > /etc/hosts" &>> ${LOG_FILE}
-echo "Step 15: Copying new fstab"
+echo "Step 16: Copying new fstab"
cp ${TOOL_RES_PATH}/fstab etc/fstab &>> ${LOG_FILE}
-echo "Step 16: Setting up networking"
+echo "Step 17: Setting up networking"
echo 'config_eth0=( "dhcp" )' > etc/conf.d/net
cp etc/init.d/net.lo etc/init.d/net.eth0
linux32 chroot . rc-update add net.eth0 default &>> ${LOG_FILE}
-echo "Step 17: Setting up kernel"
+echo "Step 18: Setting up kernel"
# If we got the flag, used a cached kernel to reduce build times for testing
if [[ ${FLAGS_cachedkernel} -eq ${FLAGS_TRUE} ]]; then
echo "Using cached kernel" &>> ${LOG_FILE}
@@ -227,16 +239,16 @@ else
cp usr/src/linux/arch/i386/boot/bzImage boot/kernel &>> ${LOG_FILE} || handle_error "Error copying kernel"
fi
-echo "Step 18: Setting root password"
+echo "Step 19: Setting root password"
linux32 chroot . /bin/bash -c "echo 'root:${ROOT_PASSWORD}' | chpasswd" &>> ${LOG_FILE} || handle_error "Error setting root password"
-echo "Step 19: Processing packages list"
+echo "Step 20: Processing packages list"
for PACKAGE in ${PACKAGES_LIST}; do
echo "Installing ${PACKAGE}" &>> ${LOG_FILE}
linux32 chroot . emerge --jobs=${NUM_JOBS} ${PACKAGE} &>> ${LOG_FILE} || handle_error "Error emerging ${PACKAGE}"
done
-echo "Step 20: Adding default user"
+echo "Step 21: Adding default user"
linux32 chroot . useradd -g users -G lp,wheel,audio,cdrom,portage -m ${DEFAULT_USERNAME} || handle_error "Error adding default user"
linux32 chroot . /bin/bash -c "echo '${DEFAULT_USERNAME}:${DEFAULT_PASSWORD}' | chpasswd" &>> ${LOG_FILE} || handle_error "Error setting default user password"
@@ -249,13 +261,13 @@ then
linux32 chroot . usermod -a vboxguest ${DEFAULT_USERNAME}
fi
-echo "Step 21: Cleaning up make.conf"
+echo "Step 22: Cleaning up make.conf"
if [ -n ${EMERGE_PROXY} ]; then
sed -i '/http_proxy/ d' etc/make.conf
fi
sed -i '/MAKEOPTS/ d' etc/make.conf
-echo "Step 22: Installing extlinux"
+echo "Step 23: Installing extlinux"
extlinux --heads 255 --sectors 63 --install boot &>> ${LOG_FILE} || handle_error "Error installing extlinux"
dd if=/usr/lib/extlinux/mbr.bin of=../${IMAGE_NAME} conv=notrunc &>> ${LOG_FILE} || handle_error "Error copying extlinux MBR"
cp ${TOOL_RES_PATH}/extlinux.conf boot/ || handle_error "Error copying extlinux configuration"
@@ -291,6 +303,6 @@ if [[ ${FLAGS_compress} -eq ${FLAGS_TRUE} ]]; then
IMAGE_OUT="${BUILD_ID}.tar.gz"
fi
-echo "Step 23: Image build completed!"
+echo "Step 24: Image build completed!"
echo "Your image is here: ${IMAGES_OUTPUT_PATH}/${IMAGE_OUT}"
echo "Your log file is here: ${IMAGES_OUTPUT_PATH}/${BUILD_ID}.log"
diff --git a/daemon.php b/daemon.php
index 6704053..65d7d2b 100644
--- a/daemon.php
+++ b/daemon.php
@@ -53,7 +53,7 @@
function image_build($job)
{
- $progressMagic = 23;
+ $progressMagic = 24;
$handle = $job->handle();
$handlehash = md5($handle);
next reply other threads:[~2011-08-02 16:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-02 16:48 Liam McLoughlin [this message]
-- strict thread matches above, loose matches on Subject: below --
2011-08-02 16:48 [gentoo-commits] proj/gentoaster:webui commit in: /, configs/ Liam McLoughlin
2011-07-28 4:51 Liam McLoughlin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c80e652a6becc61fa29e8ae5f2a8c8b5c9ee3771.hexxeh@gentoo \
--to=hexxeh@hexxeh.net \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox