3 git clone http://git.openstack.org/stackforge/compass-core -b dev/experimental
6 source venv/bin/activate
7 pip install -i http://pypi.douban.com/simple -e .
8 if [[ ! -f /var/log/compass ]]; then
9 sudo mkdir /var/log/compass
10 sudo chown -R 777 /var/log/compass
12 if [[ ! -f /etc/compass ]]; then
13 sudo mkdir /etc/compass
14 sudo cp -rf conf/setting /etc/compass/.
16 cp bin/switch_virtualenv.py.template bin/switch_virtualenv.py
17 sed -i "s|\$PythonHome|$VIRTUAL_ENV|g" bin/switch_virtualenv.py
18 #source ../compass-install/ci/allinone.conf
19 /usr/bin/expect ${SCRIPT_DIR}/../deploy/remote_excute.exp \
20 "ssh root@${COMPASS_SERVER} mkdir -p /opt/compass/bin/ansible_callbacks" vagrant
22 /usr/bin/expect ${SCRIPT_DIR}/../deploy/remote_excute.exp \
23 "scp -r ${SCRIPT_DIR}/../deploy/status_callback.py root@${COMPASS_SERVER}:/opt/compass/bin/ansible_callbacks/status_callback.py" \
25 bin/client.py --logfile= --loglevel=debug --logdir= --compass_server="${COMPASS_SERVER_URL}" \
26 --compass_user_email="${COMPASS_USER_EMAIL}" --compass_user_password="${COMPASS_USER_PASSWORD}" \
27 --cluster_name="${CLUSTER_NAME}" --language="${LANGUAGE}" --timezone="${TIMEZONE}" \
28 --hostnames="${HOSTNAMES}" --partitions="${PARTITIONS}" --subnets="${SUBNETS}" \
29 --adapter_os_pattern="${ADAPTER_OS_PATTERN}" --adapter_name="${ADAPTER_NAME}" \
30 --adapter_target_system_pattern="${ADAPTER_TARGET_SYSTEM_PATTERN}" \
31 --adapter_flavor_pattern="${ADAPTER_FLAVOR_PATTERN}" \
32 --http_proxy="${PROXY}" --https_proxy="${PROXY}" --no_proxy="${IGNORE_PROXY}" \
33 --ntp_server="${NTP_SERVER}" --dns_servers="${NAMESERVERS}" --domain="${DOMAIN}" \
34 --search_path="${SEARCH_PATH}" --default_gateway="${GATEWAY}" \
35 --server_credential="${SERVER_CREDENTIAL}" --local_repo_url="${LOCAL_REPO_URL}" \
36 --os_config_json_file="${OS_CONFIG_FILENAME}" --service_credentials="${SERVICE_CREDENTIALS}" \
37 --console_credentials="${CONSOLE_CREDENTIALS}" --host_networks="${HOST_NETWORKS}" \
38 --network_mapping="${NETWORK_MAPPING}" --package_config_json_file="${PACKAGE_CONFIG_FILENAME}" \
39 --host_roles="${HOST_ROLES}" --default_roles="${DEFAULT_ROLES}" --switch_ips="${SWITCH_IPS}" \
40 --machines=${machines//\'} --switch_credential="${SWITCH_CREDENTIAL}" \
41 --deployment_timeout="${DEPLOYMENT_TIMEOUT}" --${POLL_SWITCHES_FLAG} --dashboard_url="${DASHBOARD_URL}" \
42 --cluster_vip="${VIP}"
46 sudo vagrant destroy compass_nodocker
47 if [[ $deploy_result != 0 ]]; then
48 echo "deployment failed"
51 echo "deployment complete"