Merge "[dev_setup] Chef Installation Clean Up"

This commit is contained in:
Jesse Zhang 2012-03-29 18:26:09 +00:00 коммит произвёл Gerrit Code Review
Родитель 943643b83c 9d3f45176f
Коммит fb6fc2f4f5
1 изменённых файлов: 4 добавлений и 14 удалений

Просмотреть файл

@ -95,24 +95,14 @@ if [ $? == 0 ]; then
fi
fi
# Install chef if required.
which chef-solo
if [ $? != 0 ]; then
if [[ $ALL != true ]]; then
read -p "chef-solo is required, should I install it? [Y/n]"
if [[ $REPLY =~ ^[nN]$ ]]; then
exit 0
fi
fi
# Install chef
if ! (apt-cache policy | grep opscode); then
echo "deb http://apt.opscode.com/ `lsb_release -cs`-0.10 main" | sudo tee /etc/apt/sources.list.d/opscode.list
wget -qO - http://apt.opscode.com/packages@opscode.com.gpg.key | sudo apt-key add -
echo chef chef/chef_server_url select none | sudo /usr/bin/debconf-set-selections
run_cmd apt-get $APT_CONFIG update -qq
run_cmd apt-get $APT_CONFIG install -qym chef
else
run_cmd apt-get $APT_CONFIG update -qq
fi
run_cmd apt-get $APT_CONFIG update -qq
run_cmd apt-get $APT_CONFIG install -qym chef
run_cmd apt-get $APT_CONFIG install -qym git-core
[ -d $CLOUDFOUNDRY_HOME ] || mkdir $CLOUDFOUNDRY_HOME