builders:
- shell:
- !include-raw: common/scripts/update-jenkins-jobs.sh
+ !include-raw: common/scripts/update_jenkins_jobs.sh
publishers:
- post-tasks:
- matches:
- log-text: '.'
escalate-status: true
- script: !include-raw: common/scripts/update-jenkins-cleanup.sh
\ No newline at end of file
+ script: !include-raw: common/scripts/update_jenkins_cleanup.sh
\ No newline at end of file
deactivate
fi
-
-parameter_string=''
-if [ ! -z ${IMAGE_NAME} ] ; then
- parameter_string="${parameter_string} --parameter 'image=${IMAGE_NAME}'"
+parameter_string=""
+if [ ! -z "${FLAVOR_NAME}" ] ; then
+ parameter_string="$parameter_string --parameter \"flavor=${FLAVOR_NAME}\""
fi
-if [ ! -z ${FLAVOR_NAME} ] ; then
- parameter_string="${parameter_string} --parameter 'flavor=${FLAVOR_NAME}'"
+if [ ! -z "${IMAGE_NAME}" ] ; then
+ parameter_string="$parameter_string --parameter \"image=${IMAGE_NAME}\""
fi
-if [ ! -z ${JENKINS_LABELS} ] ; then
- parameter_string="${parameter_string} --parameter 'jenkins_labels=${JENKINS_LABELS}'"
+if [ ! -z "${JENKINS_LABELS}" ] ; then
+ parameter_string="$parameter_string --parameter \"jenkins_labels=${JENKINS_LABELS}\""
fi
# MAC OS compatibility, for manual usage
-if [ $(which md5sum) ] ; then
+if command -v md5sum ; then
md5_cmd="md5sum"
else
md5_cmd="md5"
STACK_NAME="${STACK_PREFIX:-swarm_slave}_$(date +%s | "${md5_cmd}" | head -c 4)"
+set +x
source "${OPENSTACK_CLIENTS_VENV}"/bin/activate
+set -x
source "${OPENRC_FILE?}"
- openstack stack create -t "${HEAT_STACK_YAML}" "${STACK_NAME}"
+ echo "openstack stack create -t ${HEAT_STACK_YAML} ${parameter_string} ${STACK_NAME}" | bash -
+ openstack stack output show "${STACK_NAME}" --all
deactivate
\ No newline at end of file