add postinstall.sh
This commit is contained in:
parent
760d0b80d6
commit
4fe27fd1cc
|
@ -0,0 +1,20 @@
|
||||||
|
#!/bin/bash
|
||||||
|
################################################################
|
||||||
|
# NAME
|
||||||
|
# postinstall.sh post install some sw and configure after
|
||||||
|
# vagrant virtual machine installed for ubuntu
|
||||||
|
# NOTE
|
||||||
|
# the base box is ubuntu 12.04 lts, which is download from
|
||||||
|
#
|
||||||
|
################################################################
|
||||||
|
echo "postinstall start."
|
||||||
|
|
||||||
|
VAGRANTPATH="/vagrant"
|
||||||
|
|
||||||
|
# change source list
|
||||||
|
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
|
||||||
|
cp ${VAGRANTPATH}/sources.list /etc/apt/
|
||||||
|
sudo apt-get update
|
||||||
|
|
||||||
|
# install some necessary sowftware
|
||||||
|
sudo apt-get install -y emacs zsh
|
|
@ -1,2 +1,7 @@
|
||||||
echo "abcd" >> abcd.txt
|
echo "begin posinstall.sh" >> pos.log
|
||||||
echo "$ifconfig" >> abcd.txt
|
echo "`date`" >> pos.log
|
||||||
|
echo "---------------------------" >> pos.log
|
||||||
|
/bin/bash /vagrant/postinstall.sh >> pos.log 2>&1
|
||||||
|
echo "---------------------------" >> pos.log
|
||||||
|
echo "finish posinstall.sh" >> pos.log
|
||||||
|
echo "`date`" >> pos.log
|
||||||
|
|
|
@ -0,0 +1,22 @@
|
||||||
|
deb http://mirrors.163.com/ubuntu/ precise main universe restricted multiverse
|
||||||
|
deb-src http://mirrors.163.com/ubuntu/ precise main universe restricted multiverse
|
||||||
|
deb http://mirrors.163.com/ubuntu/ precise-security universe main multiverse restricted
|
||||||
|
deb-src http://mirrors.163.com/ubuntu/ precise-security universe main multiverse restricted
|
||||||
|
deb http://mirrors.163.com/ubuntu/ precise-updates universe main multiverse restricted
|
||||||
|
deb http://mirrors.163.com/ubuntu/ precise-proposed universe main multiverse restricted
|
||||||
|
deb-src http://mirrors.163.com/ubuntu/ precise-proposed universe main multiverse restricted
|
||||||
|
deb http://mirrors.163.com/ubuntu/ precise-backports universe main multiverse restricted
|
||||||
|
deb-src http://mirrors.163.com/ubuntu/ precise-backports universe main multiverse restricted
|
||||||
|
deb-src http://mirrors.163.com/ubuntu/ precise-updates universe main multiverse restricted
|
||||||
|
|
||||||
|
deb http://ftp.sjtu.edu.cn/ubuntu/ precise main multiverse restricted universe
|
||||||
|
deb http://ftp.sjtu.edu.cn/ubuntu/ precise-backports main multiverse restricted universe
|
||||||
|
deb http://ftp.sjtu.edu.cn/ubuntu/ precise-proposed main multiverse restricted universe
|
||||||
|
deb http://ftp.sjtu.edu.cn/ubuntu/ precise-security main multiverse restricted universe
|
||||||
|
deb http://ftp.sjtu.edu.cn/ubuntu/ precise-updates main multiverse restricted universe
|
||||||
|
deb http://ftp.sjtu.edu.cn/ubuntu-cn/ precise main multiverse restricted universe
|
||||||
|
deb-src http://ftp.sjtu.edu.cn/ubuntu/ precise main multiverse restricted universe
|
||||||
|
deb-src http://ftp.sjtu.edu.cn/ubuntu/ precise-backports main multiverse restricted universe
|
||||||
|
deb-src http://ftp.sjtu.edu.cn/ubuntu/ precise-proposed main multiverse restricted universe
|
||||||
|
deb-src http://ftp.sjtu.edu.cn/ubuntu/ precise-security main multiverse restricted universe
|
||||||
|
deb-src http://ftp.sjtu.edu.cn/ubuntu/ precise-updates main multiverse restricted universe
|
Loading…
Reference in New Issue