From 43e00660c30d5f7b78d9eacfe2540a0c92fe5bb9 Mon Sep 17 00:00:00 2001 From: Roman Prykhodchenko Date: Tue, 15 Oct 2013 17:03:15 +0300 Subject: [PATCH] Install Ironic client Since python-ironicclient was published to github it's reasonable to include it to the default Ironic set up. Change-Id: Id1d0209959a3b482977b5e710c0885c714ad7e10 --- lib/ironic | 20 ++++++++++++++------ stack.sh | 1 + stackrc | 4 ++++ 3 files changed, 19 insertions(+), 6 deletions(-) diff --git a/lib/ironic b/lib/ironic index f3b4a72f66..89d0edc1a4 100644 --- a/lib/ironic +++ b/lib/ironic @@ -11,6 +11,7 @@ # ``stack.sh`` calls the entry points in this order: # # install_ironic +# install_ironicclient # configure_ironic # init_ironic # start_ironic @@ -27,6 +28,7 @@ set +o xtrace # Set up default directories IRONIC_DIR=$DEST/ironic +IRONICCLIENT_DIR=$DEST/python-ironicclient IRONIC_AUTH_CACHE_DIR=${IRONIC_AUTH_CACHE_DIR:-/var/cache/ironic} IRONIC_CONF_DIR=${IRONIC_CONF_DIR:-/etc/ironic} IRONIC_CONF_FILE=$IRONIC_CONF_DIR/ironic.conf @@ -45,6 +47,18 @@ IRONIC_HOSTPORT=${IRONIC_HOSTPORT:-$SERVICE_HOST:6385} # Functions # --------- +# install_ironic() - Collect source and prepare +function install_ironic() { + git_clone $IRONIC_REPO $IRONIC_DIR $IRONIC_BRANCH + setup_develop $IRONIC_DIR +} + +# install_ironicclient() - Collect sources and prepare +function install_ironicclient() { + git_clone $IRONICCLIENT_REPO $IRONICCLIENT_DIR $IRONICCLIENT_BRANCH + setup_develop $IRONICCLIENT_DIR +} + # cleanup_ironic() - Remove residual data files, anything left over from previous # runs that would need to clean up. function cleanup_ironic() { @@ -170,12 +184,6 @@ function init_ironic() { create_ironic_accounts } -# install_ironic() - Collect source and prepare -function install_ironic() { - git_clone $IRONIC_REPO $IRONIC_DIR $IRONIC_BRANCH - setup_develop $IRONIC_DIR -} - # start_ironic() - Start running processes, including screen function start_ironic() { # Start Ironic API server, if enabled. diff --git a/stack.sh b/stack.sh index 14ec023a51..2501cd0eb4 100755 --- a/stack.sh +++ b/stack.sh @@ -722,6 +722,7 @@ fi if is_service_enabled ir-api ir-cond; then install_ironic + install_ironicclient configure_ironic fi diff --git a/stackrc b/stackrc index 3f740b5678..0151672c1d 100644 --- a/stackrc +++ b/stackrc @@ -104,6 +104,10 @@ HORIZON_BRANCH=${HORIZON_BRANCH:-master} IRONIC_REPO=${IRONIC_REPO:-${GIT_BASE}/openstack/ironic.git} IRONIC_BRANCH=${IRONIC_BRANCH:-master} +# ironic client +IRONICCLIENT_REPO=${IRONICCLIENT_REPO:-${GIT_BASE}/openstack/python-ironicclient.git} +IRONICCLIENT_BRANCH=${IRONICCLIENT_BRANCH:-master} + # unified auth system (manages accounts/tokens) KEYSTONE_REPO=${KEYSTONE_REPO:-${GIT_BASE}/openstack/keystone.git} KEYSTONE_BRANCH=${KEYSTONE_BRANCH:-master}