7 # Standard Debian install
9 # prepare on hydra and use debproxy for speed
11 # have dedicated hard-drives for swap and home
15 # hostname: neurodebian
18 # Needs to be assured since it got reset to debian
19 hostname neurodebian # this is not a permanent change
20 echo "neurodebian" >| /etc/hostname # make it permanent
21 sed -i -e 's/^127\.0\.1\.1.*/127.0.1.1\tneurodebian/g' /etc/hosts
23 # all file in one partition
30 # Do a minimal install
31 # --------------------
33 # All files in one partition/
34 # just base system, run selection, but no tasks (not even 'Standard system')
36 # set root password to 'neurodebian' too
37 #echo "Set root passwd:"
40 apt-get install --no-install-recommends -y etckeeper
43 git config --global user.name NeuroDebian
44 git config --global user.email nd@localhost
49 # Add sources.list for backports and neurodebian
50 wget -O /etc/apt/sources.list.d/neuro.debian.net.list http://neuro.debian.net/_static/neurodebian.squeeze.us-nh.sources.list
52 echo "deb http://backports.debian.org/debian-backports squeeze-backports main contrib non-free" > /etc/apt/sources.list.d/backports.debian.org.list
53 cat << EOT > /etc/apt/preferences.d/backports.debian.org.pref
55 Pin: release a=squeeze-backports
60 # Backports' Release files signed with both ftpmaster and old backports keys
61 # That causes APT to spit out a warning, but to not confuse users, lets simply
62 # obtain that key if possible
63 gpg --keyserver hkp://subkeys.pgp.net --recv-keys 16BA136C && \
64 gpg --export 16BA136C | apt-key add - || :
66 apt-get install -y --allow-unauthenticated neurodebian-keyring
69 # to cheat the VM check
71 # Forcefully install guest additions from backports so we are
72 # compatible with VirtualBox 4.x series
73 apt-get install -y -t squeeze-backports virtualbox-ose-guest-dkms
74 # to get all the rest stuff in recommends
75 apt-get install -y dkms neurodebian-guest-additions
77 apt-get install --no-install-recommends -y \
78 gnome-core mc evince bash-completion ntpdate file-roller gnome-utils \
79 gnome-themes eog vim reportbug \
80 software-center gdebi gedit-plugins gnome-media synaptic menu less libxp6
82 # Clean-up installed development files which got pulled in for
83 # VM guest additions (to build kernel modules via DKMS)
84 apt-get purge -y libc6-dev
85 dpkg -l | awk '/^ii.*[ \t]linux-headers/{print $2;}' | xargs -r apt-get purge -y
87 # Gnome optional pulled by gnome-core:
88 apt-get purge -y gnome-core evolution-common evolution libevolution
93 # intermediate cleanup to prevent virtual harddrive from fragmenting too much
94 find /var/cache/apt/archives/ -name '*.deb' -delete
96 # cleanup unwanted stuff
97 # video drivers (all but vesa)
98 apt-get purge -y $(apt-cache search --names-only --installed xserver-xorg-video | grep xserver-xorg-video | cut -d ' ' -f 1,1) xserver-xorg-video-vesa+
99 apt-get purge -y brasero
101 # and whatever is obsolete
102 apt-get autoremove --purge -y
105 # use NeuroDebian website as default homepage
106 sed -i -e 's,http://www.debian.org,http://neuro.debian.net,g' /etc/chromium-browser/master_preferences
108 # reduce grub timeout to speed up boot of VM
109 sed -i -e 's/GRUB_TIMEOUT=5/GRUB_TIMEOUT=1/g' /etc/default/grub
112 # finally configure geomirror for APT and disable deb-src lists
113 sed -i -e "s/10.0.0.1:9999/$(dpkg --print-architecture)-geomirror.debian.net/" \
114 -e "s/^deb-src/#deb-src/" /etc/apt/sources.list
116 etckeeper commit "Initial VM setup done"
118 # Create a link to automatically mounted Shared folder
119 # Created by the Welcome Wizard
120 #sudo -u brain ln -s /mnt/host /home/brain/