2 ###############################################################################
3 # Copyright (c) 2015 Huawei Tech.
5 # All rights reserved. This program and the accompanying materials
6 # are made available under the terms of the Apache License, Version 2.0
7 # which accompanies this distribution, and is available at
8 # http://www.apache.org/licenses/LICENSE-2.0
9 ##############################################################################
13 RELENG_REPO=https://gerrit.opnfv.org/gerrit/releng
14 RELENG_REPO_DIR=/tmp/opnfvrepo/releng
15 #RELENG_BRANCH=master # branch, tag, sha1 or refspec
18 INSTALLER_IP=10.20.0.2
20 NODE_NAME=opnfv-jump-2
21 EXTERNAL_NET=net04_ext
23 echo "INFO: Creating openstack credentials .."
25 if [ -d $RELENG_REPO_DIR ]; then
26 rm -rf ${RELENG_REPO_DIR}
28 mkdir -p ${RELENG_REPO_DIR}
29 git config --global http.sslVerify false
30 git clone ${RELENG_REPO} ${RELENG_REPO_DIR}
32 # Create openstack credentials
33 $RELENG_REPO_DIR/utils/fetch_os_creds.sh \
35 -i ${INSTALLER_TYPE} -a ${INSTALLER_IP}
39 # FIXME: Temporary OPNFV playground hack
40 if [ "$INSTALLER_TYPE" == "fuel" ]; then
41 ssh_opts="-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no"
42 if sshpass -p r00tme ssh 2>/dev/null $ssh_opts root@${INSTALLER_IP} \
43 fuel environment --env 1 | grep opnfv-virt; then
44 echo "INFO: applying OPNFV playground hack"
45 export OS_ENDPOINT_TYPE='publicURL'
49 export EXTERNAL_NET INSTALLER_TYPE NODE_NAME