1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-01-26 10:03:37 +03:00
one/.travis/tests/03-oned.sh

38 lines
1.7 KiB
Bash
Raw Normal View History

2019-01-31 11:14:43 +01:00
# -------------------------------------------------------------------------- #
# Copyright 2002-2019, OpenNebula Project, OpenNebula Systems #
# #
# Licensed 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. #
#--------------------------------------------------------------------------- #
# install oned system wide
2019-01-31 11:40:56 +01:00
sudo ./install.sh -u travis
2019-01-31 11:14:43 +01:00
2019-01-31 11:56:57 +01:00
# Set credentials
mkdir $HOME/.one
echo "oneadmin:opennebula" > $HOME/.one/one_auth
2019-01-31 15:05:45 +01:00
# Install gems
2019-02-28 19:31:40 +01:00
sudo /usr/share/one/install_gems --yes
2019-01-31 15:05:45 +01:00
2019-02-28 19:31:40 +01:00
# Enable dummy drivers
sudo chmod o+w /etc/one/oned.conf
echo 'IM_MAD = [ NAME="dummy", SUNSTONE_NAME="Testing", EXECUTABLE="one_im_dummy"]' >> /etc/one/oned.conf
echo 'VM_MAD = [ NAME="dummy", SUNSTONE_NAME="Testing", EXECUTABLE="one_vmm_dummy",TYPE="xml" ]' >> /etc/one/oned.conf
2019-01-31 11:14:43 +01:00
2019-02-28 19:31:40 +01:00
# start oned
2019-01-31 11:14:43 +01:00
one start
# check it's up
timeout 60 sh -c 'until nc -z $0 $1; do sleep 1; done' localhost 2633