Last active
December 16, 2015 04:59
-
-
Save tonypiazza/5380980 to your computer and use it in GitHub Desktop.
A BASH script to setup everything we need for a Cassandra development machine with Ubuntu Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Script written by Tony Piazza (https://gist.github.com/tonypiazza) | |
# make sure we have sufficient privileges | |
if [ $UID != 0 ] | |
then | |
echo -e "Insufficient privileges!" | |
exit 1 | |
fi | |
echo "-----> Adding required PPAs..." | |
add-apt-repository -y ppa:webupd8team/java | |
apt-get update | |
echo "-----> Downloading Cassandra..." | |
wget -P ~/Downloads http://mirror.cc.columbia.edu/pub/software/apache/cassandra/2.0.2/apache-cassandra-2.0.2-bin.tar.gz | |
echo "-----> Installing Java..." | |
echo debconf shared/accepted-oracle-license-v1-1 select true | debconf-set-selections | |
echo debconf shared/accepted-oracle-license-v1-1 seen true | debconf-set-selections | |
apt-get -y install oracle-java7-installer | |
echo "-----> Installing Eclipse..." | |
eclipse_bin="#!/bin/sh | |
export ECLIPSE_HOME='/opt/eclipse' | |
\$ECLIPSE_HOME/eclipse \$*" | |
eclipse_desktop="[Desktop Entry] | |
Encoding=UTF-8 | |
Name=Eclipse | |
Comment=Eclipse IDE | |
Exec=eclipse | |
Icon=/opt/eclipse/icon.xpm | |
Terminal=false | |
Type=Application | |
Categories=GNOME;Application;Development; | |
StartupNotify=true" | |
wget -P ~/Downloads http://mirror.cc.columbia.edu/pub/software/eclipse/technology/epp/downloads/release/kepler/SR1/eclipse-jee-kepler-SR1-linux-gtk-x86_64.tar.gz | |
cd /opt | |
tar -zxf ~/Downloads/eclipse-jee-kepler-SR1-linux-gtk-x86_64.tar.gz | |
touch /usr/bin/eclipse | |
chmod 755 /usr/bin/eclipse | |
echo -e "$eclipse_bin" | tee /usr/bin/eclipse | |
echo -e "$eclipse_desktop" | tee /usr/share/applications/eclipse.desktop | |
cd | |
echo "-----> Installing Ant..." | |
apt-get -y install ant | |
echo "-----> Installing LibYAML..." | |
wget -P ~/Downloads http://pyyaml.org/download/libyaml/yaml-0.1.4.tar.gz | |
tar -zxf ~/Downloads/yaml-0.1.4.tar.gz | |
cd yaml-0.1.4 | |
./configure | |
make | |
make install | |
cd | |
echo "-----> Installing python-dev..." | |
apt-get -y install python-dev | |
echo "-----> Installing PyYAML..." | |
wget -P ~/Downloads http://pyyaml.org/download/pyyaml/PyYAML-3.10.tar.gz | |
tar -zxf ~/Downloads/PyYAML-3.10.tar.gz | |
cd PyYAML-3.10 | |
python setup.py --with-libyaml install | |
cd | |
echo "-----> Installing JNA..." | |
apt-get -y install libjna-java | |
echo "-----> Installing CCM..." | |
cd /opt | |
mkdir ccm | |
cd ccm | |
git init | |
git pull https://github.com/pcmanus/ccm.git | |
./setup.py install | |
cd | |
echo "-----> Reinstalling VMware Tools..." | |
apt-get -y autoremove | |
apt-get -y install build-essential linux-headers-`uname -r` psmisc | |
vmware-config-tools.pl -d | |
echo "-----> Installation completed in $SECONDS seconds." |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Nice Tony! I'll see about modding your script for dse.
Lorina