Skip to content

Instantly share code, notes, and snippets.

@shenqihui
Last active November 5, 2015 10:23
Show Gist options
  • Save shenqihui/c869e2953c5f226d6de0 to your computer and use it in GitHub Desktop.
Save shenqihui/c869e2953c5f226d6de0 to your computer and use it in GitHub Desktop.
ubuntu 1404 init sh
# aliyun apt source
# sudo sh -c 'echo "deb http://cn.archive.ubuntu.com/ubuntu/ trusty main restricted \n\
# deb-src http://cn.archive.ubuntu.com/ubuntu/ trusty main restricted \n\
# deb http://cn.archive.ubuntu.com/ubuntu/ trusty-updates main restricted \n\
# deb-src http://cn.archive.ubuntu.com/ubuntu/ trusty-updates main restricted \n\
# deb http://cn.archive.ubuntu.com/ubuntu/ trusty universe \n\
# deb-src http://cn.archive.ubuntu.com/ubuntu/ trusty universe \n\
# deb http://cn.archive.ubuntu.com/ubuntu/ trusty-updates universe \n\
# deb-src http://cn.archive.ubuntu.com/ubuntu/ trusty-updates universe \n\
# deb http://cn.archive.ubuntu.com/ubuntu/ trusty multiverse \n\
# deb-src http://cn.archive.ubuntu.com/ubuntu/ trusty multiverse \n\
# deb http://cn.archive.ubuntu.com/ubuntu/ trusty-updates multiverse \n\
# deb-src http://cn.archive.ubuntu.com/ubuntu/ trusty-updates multiverse \n\
# deb http://cn.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse \n\
# deb-src http://cn.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse \n\
# deb http://security.ubuntu.com/ubuntu trusty-security main restricted \n\
# deb-src http://security.ubuntu.com/ubuntu trusty-security main restricted \n\
# deb http://security.ubuntu.com/ubuntu trusty-security universe \n\
# deb-src http://security.ubuntu.com/ubuntu trusty-security universe \n\
# deb http://security.ubuntu.com/ubuntu trusty-security multiverse \n\
# deb-src http://security.ubuntu.com/ubuntu trusty-security multiverse \n\
# " > /etc/apt/sources.list'
# sudo sh -c 'echo "deb http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse \n\
# deb http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse \n\
# deb http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse \n\
# deb http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse \n\
# deb http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse \n\
# deb-src http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse \n\
# deb-src http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse \n\
# deb-src http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse \n\
# deb-src http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse \n\
# deb-src http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse \n\
# " > /etc/apt/sources.list '
sudo sh -c 'echo "deb http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse \n\
deb http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse \n\
deb http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse \n\
deb http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse \n\
deb http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse \n\
deb-src http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse \n\
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse \n\
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse \n\
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse \n\
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse \n\
" > /etc/apt/sources.list'
# sudo sh -c 'echo "deb http://debian.ustc.edu.cn/ubuntu/ trusty main multiverse restricted universe \n\
# deb http://debian.ustc.edu.cn/ubuntu/ trusty-backports main multiverse restricted universe \n\
# deb http://debian.ustc.edu.cn/ubuntu/ trusty-proposed main multiverse restricted universe \n\
# deb http://debian.ustc.edu.cn/ubuntu/ trusty-security main multiverse restricted universe \n\
# deb http://debian.ustc.edu.cn/ubuntu/ trusty-updates main multiverse restricted universe \n\
# deb-src http://debian.ustc.edu.cn/ubuntu/ trusty main multiverse restricted universe \n\
# deb-src http://debian.ustc.edu.cn/ubuntu/ trusty-backports main multiverse restricted universe \n\
# deb-src http://debian.ustc.edu.cn/ubuntu/ trusty-proposed main multiverse restricted universe \n\
# deb-src http://debian.ustc.edu.cn/ubuntu/ trusty-security main multiverse restricted universe \n\
# deb-src http://debian.ustc.edu.cn/ubuntu/ trusty-updates main multiverse restricted universe \n\
# " > /etc/apt/sources.list'
export LC_ALL=C
export LANGUAGE="en_US.UTF-8"
export LANG=en_US:zh_CN.UTF-8
echo 'sudo apt-get update'
sudo apt-get update
echo 'install base package'
sudo apt-get install -y wget
sudo apt-get install -y vim
sudo apt-get install -y curl
sudo apt-get install -y git
sudo apt-get install -y zsh
sudo apt-get install -y build-essential
sudo apt-get install -y nginx
sudo apt-get install -y python-dev
sudo apt-get install -y python-pip
sudo apt-get install -y docker.io
sudo apt-get install -y libssl0.9.8
sudo apt-get install -y python-setuptools
sudo pip install supervisor
sudo pip install virtualenv
sudo pip install uwsgi
sudo apt-get install -y php5
sudo apt-get install -y mongodb
sudo apt-get install -y mcrypt
sudo apt-get install -y libssl0.9.8
sudo apt-get install -y rrdtool
sudo usermod -aG docker vagrant
echo 'use zsh'
chsh -s /bin/zsh
echo 'clone oh-my-zsh'
wget https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | sh
sudo sh -c 'curl -sL https://deb.nodesource.com/setup|bash'
sudo apt-get install -y nodejs
sudo npm install -g bower
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment