安装JDK
yum install -y java-1.8.0-openjdk
java -version
设置环境变量
cp /etc/profile /etc/profile_backup
echo 'export JAVA_HOME=/usr/lib/jvm/jre-1.8.0-openjdk' | sudo tee -a /etc/profile
echo 'export JRE_HOME=/usr/lib/jvm/jre' | sudo tee -a /etc/profile
source /etc/profile
echo $JAVA_HOME
echo $JRE_HOME
安装Scala
cd /home/user/
wget http://downloads.lightbend.com/scala/2.11.8/scala-2.11.8.rpm
yum install -y scala-2.11.8.rpm
scala -version