Merge "[AMQP 1.0] Setup the amqp1 test environment on ubuntu"

This commit is contained in:
Jenkins 2016-12-23 15:02:36 +00:00 committed by Gerrit Code Review
commit b0507a6bdb
5 changed files with 13 additions and 7 deletions

View File

@ -24,6 +24,7 @@ qpidd [platform:dpkg amqp1]
sasl2-bin [platform:dpkg amqp1] sasl2-bin [platform:dpkg amqp1]
uuid-dev [platform:dpkg amqp1] uuid-dev [platform:dpkg amqp1]
swig [platform:dpkg amqp1] swig [platform:dpkg amqp1]
libsasl2-modules [platform:dpkg amqp1]
# AMQP1 rpm # AMQP1 rpm
qpid-cpp-server [platform:rpm amqp1] qpid-cpp-server [platform:rpm amqp1]

View File

@ -47,9 +47,6 @@ case $RPC_BACKEND in
sudo apt-get update -y sudo apt-get update -y
sudo apt-get install -y redis-server python-redis sudo apt-get install -y redis-server python-redis
;; ;;
amqp1)
sudo yum install -y qpid-cpp-server qpid-proton-c-devel python-qpid-proton cyrus-sasl-lib cyrus-sasl-plain
;;
rabbit) rabbit)
sudo apt-get update -y sudo apt-get update -y
sudo apt-get install -y rabbitmq-server sudo apt-get install -y rabbitmq-server

View File

@ -115,6 +115,12 @@ EOF
function _configure_qpidd { function _configure_qpidd {
QPIDD=$(which qpidd 2>/dev/null)
if [[ ! -x "$QPIDD" ]]; then
echo "FAILURE: qpidd broker not installed"
exit 1
fi
[ -f "/usr/lib/qpid/daemon/acl.so" ] && LIBACL="load-module=/usr/lib/qpid/daemon/acl.so" [ -f "/usr/lib/qpid/daemon/acl.so" ] && LIBACL="load-module=/usr/lib/qpid/daemon/acl.so"
cat > ${DATADIR}/qpidd.conf <<EOF cat > ${DATADIR}/qpidd.conf <<EOF
@ -123,9 +129,11 @@ sasl-config=${DATADIR}/sasl2
${LIBACL} ${LIBACL}
mgmt-enable=yes mgmt-enable=yes
log-to-stderr=no log-to-stderr=no
data-dir=${DATADIR}/.qpidd
pid-dir=${DATADIR}/.qpidd
EOF EOF
if ! `$(which qpidd 2>/dev/null) --help | grep -q "sasl-service-name"`; then if ! `$QPIDD --help | grep -q "sasl-service-name"`; then
echo "This version of $QPIDD does not support SASL authentication with AMQP 1.0" echo "This version of $QPIDD does not support SASL authentication with AMQP 1.0"
cat >> ${DATADIR}/qpidd.conf <<EOF cat >> ${DATADIR}/qpidd.conf <<EOF
auth=no auth=no
@ -156,6 +164,7 @@ pwcheck_method: auxprop
auxprop_plugin: sasldb auxprop_plugin: sasldb
sasldb_path: ${DATADIR}/qpidd.sasldb sasldb_path: ${DATADIR}/qpidd.sasldb
mech_list: PLAIN ANONYMOUS mech_list: PLAIN ANONYMOUS
sql_select: dummy select
EOF EOF
} }
@ -178,6 +187,7 @@ EOF
} }
function _start_qpidd { function _start_qpidd {
chmod -R a+r ${DATADIR}
QPIDD=$(which qpidd 2>/dev/null) QPIDD=$(which qpidd 2>/dev/null)
mkfifo ${DATADIR}/out mkfifo ${DATADIR}/out
$QPIDD --log-enable trace+ --log-to-file ${DATADIR}/out --config ${DATADIR}/qpidd.conf & $QPIDD --log-enable trace+ --log-to-file ${DATADIR}/out --config ${DATADIR}/qpidd.conf &

View File

@ -28,6 +28,7 @@ PACKAGES=$(.tox/bindep/bin/bindep -b -f bindep.txt $BINDEP_PROFILE || true)
# inspired from project-config install-distro-packages.sh # inspired from project-config install-distro-packages.sh
if apt-get -v >/dev/null 2>&1 ; then if apt-get -v >/dev/null 2>&1 ; then
[ $BINDEP_PROFILE == amqp1 ] && sudo add-apt-repository -y ppa:qpid/testing
sudo apt-get -qq update sudo apt-get -qq update
sudo PATH=/usr/sbin:/sbin:$PATH DEBIAN_FRONTEND=noninteractive \ sudo PATH=/usr/sbin:/sbin:$PATH DEBIAN_FRONTEND=noninteractive \
apt-get -q --option "Dpkg::Options::=--force-confold" \ apt-get -q --option "Dpkg::Options::=--force-confold" \

View File

@ -67,7 +67,6 @@ setenv =
AMQP1_BACKEND=qpidd AMQP1_BACKEND=qpidd
ENVNAME={envname} ENVNAME={envname}
WORKDIR={toxworkdir} WORKDIR={toxworkdir}
# NOTE(kgiusti): This gate job runs on Centos 7 for now.
commands = {toxinidir}/setup-test-env-amqp1.sh python setup.py testr --slowest --testr-args='oslo_messaging.tests.functional' commands = {toxinidir}/setup-test-env-amqp1.sh python setup.py testr --slowest --testr-args='oslo_messaging.tests.functional'
[testenv:py34-func-amqp1] [testenv:py34-func-amqp1]
@ -78,7 +77,6 @@ setenv =
AMQP1_BACKEND=qpidd AMQP1_BACKEND=qpidd
ENVNAME={envname} ENVNAME={envname}
WORKDIR={toxworkdir} WORKDIR={toxworkdir}
# NOTE(kgiusti): This gate job runs on Centos 7 for now.
commands = {toxinidir}/setup-test-env-amqp1.sh python setup.py testr --slowest --testr-args='oslo_messaging.tests.functional' commands = {toxinidir}/setup-test-env-amqp1.sh python setup.py testr --slowest --testr-args='oslo_messaging.tests.functional'
[testenv:py35-func-amqp1] [testenv:py35-func-amqp1]
@ -89,7 +87,6 @@ setenv =
AMQP1_BACKEND=qpidd AMQP1_BACKEND=qpidd
ENVNAME={envname} ENVNAME={envname}
WORKDIR={toxworkdir} WORKDIR={toxworkdir}
# NOTE(kgiusti): This gate job runs on Centos 7 for now.
commands = {toxinidir}/setup-test-env-amqp1.sh python setup.py testr --slowest --testr-args='oslo_messaging.tests.functional' commands = {toxinidir}/setup-test-env-amqp1.sh python setup.py testr --slowest --testr-args='oslo_messaging.tests.functional'
[testenv:py27-func-zeromq] [testenv:py27-func-zeromq]