Preparing VirtualBox images: Difference between revisions

From genomewiki
Jump to navigationJump to search
No edit summary
No edit summary
Line 1: Line 1:
Start with a fresh Ubuntu 13.04 image.
Start with a fresh Ubuntu 13.04 image, call the main user "browser".


   apt-get install localepurge zerofree
   apt-get install localepurge zerofree
Line 11: Line 11:
   wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/ubuntu.sh
   wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/ubuntu.sh
   source ubuntu.sh
   source ubuntu.sh
It's nice to have shared folders:
  sudo addgroup vboxsf
  sufo adduser browser vboxsf
  sudo wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/rc.local -O /etc/rc.local


Once you're finished with everything ubuntu related, you can free 120 MB:
Once you're finished with everything ubuntu related, you can free 120 MB:
Line 22: Line 27:
   zerofree -v /dev/sda1
   zerofree -v /dev/sda1


To show the IP address on startup:
To show the IP address on startup, only necessary in bridged mode:


   sudo wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/show-ip-address -O /etc/network/if-up.d/show-ip-address
   sudo wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/show-ip-address -O /etc/network/if-up.d/show-ip-address

Revision as of 17:25, 24 October 2013

Start with a fresh Ubuntu 13.04 image, call the main user "browser".

 apt-get install localepurge zerofree
 # I think we don't need these packages... saves around 300MB 
 apt-get remove python3* linux-headers* aptitude man-db perl perl-modules geoip-database language-pack-gnome-en-base manpages ppp acpi iso-codes
 # wanna remove more? show packages by size: dpkg-query --show --showformat='${Package;-50}\t${Installed-Size}\n' | sort -k 2 -n
 apt-get install apache2 mysql-server mysql-client

Now install the genome browser:

 wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/ubuntu.sh
 source ubuntu.sh

It's nice to have shared folders:

 sudo addgroup vboxsf
 sufo adduser browser vboxsf
 sudo wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/rc.local -O /etc/rc.local

Once you're finished with everything ubuntu related, you can free 120 MB:

 rm -f /var/lib/apt/lists/*

Now compact the disk image: reboot, press shift on boot, selected advanced, repair mode or similar

  Select the menu option to drop into a root shell
  mount -o remount,ro /
  zerofree -v /dev/sda1

To show the IP address on startup, only necessary in bridged mode:

 sudo wget http://hgwdev.soe.ucsc.edu/~max/gbInstall/show-ip-address -O /etc/network/if-up.d/show-ip-address
 sudo chmod a+x /etc/network/if-up.d/show-ip-address