blob: 2d7ac6a8cf5f5332d3e49836f5409e81a03b5444 [file] [log] [blame]
#!/bin/bash --login
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
set -e
#first_run_wizard
echo " * installing some basic stuff..."
sudo cp -rsf /hive-dev-box/etc/* /etc/
sudo cp -rsf /hive-dev-box/bin/* /bin/
function safe_sw() {
if [ -e "/active/$1" ];then
echo " * $1 is already present"
else
/bin/sw "$@"
fi
}
safe_sw tez 0.10.1
safe_sw hadoop 3.1.2
safe_sw hive 3.1.2
#safe_sw eclipse
safe_sw maven
safe_sw protobuf
[ -d /toolbox/build/distributions ] && sudo dpkg -i /toolbox/build/distributions/*.deb
#reinit_metastore > /dev/null 2>&1
#echo "exitcode: $?"
sudo /etc/init.d/ssh start
cat /etc/motd
if [ -t 0 ];then
export USER=`whoami`
exec bash --login
else
echo "non-interactive shell detected; waiting for the end of the world... "
while :; do sleep 60;done
fi