+change_apex_pod_file_process_info() {
+ cat << EOF >> ${POD}
+process_info:
+- {testcase_name: yardstick.ha.rabbitmq, attack_process: rabbitmq_server}
+- {testcase_name: yardstick.ha.cinder_api, attack_process: cinder_wsgi}
+EOF
+}
+
+change_fuel_pod_file_process_info() {
+ cat << EOF >> ${POD}
+process_info:
+- {testcase_name: yardstick.ha.cinder_api, attack_process: cinder-wsgi}
+- {testcase_name: yardstick.ha.rabbitmq, attack_process: rabbitmq_server, attack_host: msg01}
+- {testcase_name: yardstick.ha.neutron_l3_agent, attack_process: neutron-l3-agent, attack_host: cmp01}
+- {testcase_name: yardstick.ha.database, attack_process: mysqld, attack_host: dbs01}
+EOF
+}
+
+change_compass_pod_file_process_info() {
+ cat << EOF >> ${POD}
+process_info:
+- {testcase_name: yardstick.ha.rabbitmq, attack_process: rabbitmq}
+EOF
+}
+
+change_pod_file_process_info() {
+ sudo chmod 666 ${POD}
+ echo "INFO: adapt process info for $INSTALLER_TYPE ..."
+ if [ "$INSTALLER_TYPE" == "apex" ]; then
+ change_apex_pod_file_process_info
+ elif [ "$INSTALLER_TYPE" == "fuel" ]; then
+ change_fuel_pod_file_process_info
+ elif [ "$INSTALLER_TYPE" == "compass" ]; then
+ change_compass_pod_file_process_info
+ fi
+}
+
+get_pod_file() {
+ # These packages are used for parsing yaml files and decrypting ipmi user and password.
+ sudo pip install shyaml
+ sudo yum install -y rubygems || sudo apt-get install -y ruby
+ sudo gem install hiera-eyaml
+ if [[ ${INSTALLER_TYPE} == 'compass' ]]; then
+ get_compass_pod_file
+ elif [[ ${INSTALLER_TYPE} == 'fuel' && ${DEPLOY_TYPE} == 'baremetal' ]]; then
+ get_fuel_baremetal_pod_file
+ fi
+
+ exists=`check_file_exists ${POD}`
+ if [[ $exists == 1 ]]; then
+ get_pod_file_with_scripts
+ fi
+
+ exists=`check_file_exists ${POD}`
+ if [[ $exists == 0 ]]; then
+ change_pod_file_process_info
+ else
+ echo "ERROR: cannot find file ${POD}. Please check if it exists."
+ sudo ls -al ${DOVETAIL_CONFIG}
+ exit 1
+ fi
+
+ echo "INFO: file ${POD} is:"
+ cat ${POD}
+}
+
+get_cred_file
+get_pod_file