Merge branch 'master' of git.qubes-os.org:/var/lib/qubes/git/marmarek/template-builder

This commit is contained in:
Joanna Rutkowska 2012-07-14 12:34:30 +02:00
commit 014d49e824
5 changed files with 1 additions and 34 deletions

View File

@ -22,7 +22,7 @@ yum -c $PWD/yum.conf clean packages --installroot=$INSTALLDIR
# Make sure that rpm database has right format (for rpm version in template, not host) # Make sure that rpm database has right format (for rpm version in template, not host)
echo "--> Rebuilding rpm database..." echo "--> Rebuilding rpm database..."
chroot `pwd`/mnt /bin/rpm --rebuilddb chroot `pwd`/mnt /bin/rpm --rebuilddb 2> /dev/null
echo "--> Compacting image file..." echo "--> Compacting image file..."
dd if=/dev/zero of=mnt/fillme bs=1M 2> /dev/null || true dd if=/dev/zero of=mnt/fillme bs=1M 2> /dev/null || true

Binary file not shown.

View File

@ -64,9 +64,6 @@ fi
echo "--> Installing 3rd party apps" echo "--> Installing 3rd party apps"
./add_3rd_party_software.sh ./add_3rd_party_software.sh
echo "--> Copying DispVM dotfiles dir..."
cp dispvm-dotfiles.tbz mnt/etc/
echo "--> Linking /home to /rw/home..." echo "--> Linking /home to /rw/home..."
mv mnt/home mnt/home.orig mv mnt/home mnt/home.orig
ln -sf /rw/home mnt/home ln -sf /rw/home mnt/home

View File

@ -43,8 +43,6 @@ touch $RPM_BUILD_ROOT/%{dest_dir}/volatile.img # we will create the real file in
cp clean_images/clean-volatile.img.tar $RPM_BUILD_ROOT/%{dest_dir}/clean-volatile.img.tar cp clean_images/clean-volatile.img.tar $RPM_BUILD_ROOT/%{dest_dir}/clean-volatile.img.tar
cp vm_conf_files/dispvm-prerun.sh $RPM_BUILD_ROOT/%{dest_dir}/
mkdir -p $RPM_BUILD_ROOT/%{dest_dir}/apps.templates mkdir -p $RPM_BUILD_ROOT/%{dest_dir}/apps.templates
mkdir -p $RPM_BUILD_ROOT/%{dest_dir}/apps mkdir -p $RPM_BUILD_ROOT/%{dest_dir}/apps
cp -r qubeized_images/%{template_name}-apps.templates/* $RPM_BUILD_ROOT/%{dest_dir}/apps.templates cp -r qubeized_images/%{template_name}-apps.templates/* $RPM_BUILD_ROOT/%{dest_dir}/apps.templates
@ -128,7 +126,6 @@ rm -rf $RPM_BUILD_ROOT
%{dest_dir}/clean-volatile.img.tar %{dest_dir}/clean-volatile.img.tar
%ghost %{dest_dir}/volatile.img %ghost %{dest_dir}/volatile.img
%ghost %{dest_dir}/private.img %ghost %{dest_dir}/private.img
%{dest_dir}/dispvm-prerun.sh
%attr (775,root,qubes) %dir %{dest_dir}/apps %attr (775,root,qubes) %dir %{dest_dir}/apps
%attr (775,root,qubes) %dir %{dest_dir}/apps.templates %attr (775,root,qubes) %dir %{dest_dir}/apps.templates
%attr (664,root,qubes) %{dest_dir}/apps.templates/* %attr (664,root,qubes) %{dest_dir}/apps.templates/*

View File

@ -1,27 +0,0 @@
#!/bin/sh
apps="evince /usr/libexec/evinced soffice firefox"
cat /etc/dispvm-dotfiles.tbz | tar -xjf- --overwrite -C /home/user --owner user 2>&1 >/tmp/dispvm-dotfiles-errors.log
for app in $apps ; do
echo "Launching: $app..."
$app >>/tmp/dispvm_prerun_errors.log 2>&1 &
done
echo "Sleeping..."
PREV_IO=0
while true; do
IO=`vmstat -D | awk '/read|write/ {IOs+=$1} END {print IOs}'`
if [ $IO -lt $[ $PREV_IO + 50 ] ]; then
break;
fi
PREV_IO=$IO
sleep 1
done
ps ax > /tmp/dispvm-prerun-proclist.log
cat /etc/dispvm-dotfiles.tbz | tar -xjf- --overwrite -C /home/user --owner user 2>&1 >>/tmp/dispvm-dotfiles-errors.log
echo done.