blob: dd03e2d90fff209b8a3c913e34d2a5ce22a0e3eb [file] [log] [blame]
tom5ca34372014-09-19 17:43:41 -07001#!/bin/bash
2#-------------------------------------------------------------------------------
3# Remotely configures & starts ONOS for the first time.
4#-------------------------------------------------------------------------------
5
6[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
7. $ONOS_ROOT/tools/build/envDefaults
8
9remote=$ONOS_USER@${1:-$OCI}
10
11LOG=$ONOS_INSTALL_DIR/config.log
12onos=$ONOS_INSTALL_DIR/bin/onos
13
14ssh $remote "
tom5ca34372014-09-19 17:43:41 -070015 # Wait until we reach the run-level 100
16 echo 'Waiting for cluster bootstrap...'
17 running=""
18 while [ -z \$running ]; do
19 $onos bundle:list 2>>$LOG | grep -q 'START LEVEL 100' && running=1 || sleep 2
20 done
21
tom0eaa97f2014-09-22 16:13:06 -070022 echo 'Installing ONOS bundles...'
23 $onos cluster:feature-install default onos-api 1>>$LOG 2>&1
tom2d7acb72014-09-22 22:13:00 -070024 # $onos cluster:feature-install default onos-core 1>>$LOG 2>&1
25 $onos cluster:feature-install default onos-core-trivial 1>>$LOG 2>&1
tom0eaa97f2014-09-22 16:13:06 -070026 $onos cluster:feature-install default onos-openflow 1>>$LOG 2>&1
27 $onos cluster:feature-install default onos-cli 1>>$LOG 2>&1
28 # $onos cluster:feature-install default onos-gui 1>>$LOG 2>&1
29 # $onos cluster:feature-install default onos-rest 1>>$LOG 2>&1
30 $onos cluster:feature-install default onos-app-tvue 1>>$LOG 2>&1
31 $onos cluster:feature-install default onos-app-fwd 1>>$LOG 2>&1
tom5ca34372014-09-19 17:43:41 -070032"