update configuration for qdrouter v1.0.0
Change-Id: I1355d7dd6767378bacd7394013416ac0d27c8770
This commit is contained in:
parent
e34fd233d3
commit
70e18b5738
|
@ -254,6 +254,8 @@ function _configure_qdr {
|
||||||
local url
|
local url
|
||||||
url=$(_parse_transport_url $1)
|
url=$(_parse_transport_url $1)
|
||||||
|
|
||||||
|
QDR=$(type -p qdrouterd)
|
||||||
|
|
||||||
# the location of the configuration is /etc/qpid-dispatch
|
# the location of the configuration is /etc/qpid-dispatch
|
||||||
local qdr_conf_file
|
local qdr_conf_file
|
||||||
if [ -e /etc/qpid-dispatch/qdrouterd.conf ]; then
|
if [ -e /etc/qpid-dispatch/qdrouterd.conf ]; then
|
||||||
|
@ -275,7 +277,6 @@ router {
|
||||||
workerThreads: 4
|
workerThreads: 4
|
||||||
saslConfigPath: /etc/sasl2
|
saslConfigPath: /etc/sasl2
|
||||||
saslConfigName: qdrouterd
|
saslConfigName: qdrouterd
|
||||||
debugDump: /opt/stack/amqp1
|
|
||||||
}
|
}
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
@ -283,9 +284,14 @@ EOF
|
||||||
# Create a listener for incoming connect to the router
|
# Create a listener for incoming connect to the router
|
||||||
local port
|
local port
|
||||||
port=$(echo "$url" | cut -d' ' -f2)
|
port=$(echo "$url" | cut -d' ' -f2)
|
||||||
|
|
||||||
|
# ip address field name changed to 'host' at 1.0+
|
||||||
|
local field_name
|
||||||
|
field_name=$([[ $($QDR -v) == 0.*.* ]] && echo addr || echo host)
|
||||||
|
|
||||||
cat <<EOF | sudo tee --append $qdr_conf_file
|
cat <<EOF | sudo tee --append $qdr_conf_file
|
||||||
listener {
|
listener {
|
||||||
addr: 0.0.0.0
|
${field_name}: 0.0.0.0
|
||||||
port: ${port}
|
port: ${port}
|
||||||
role: normal
|
role: normal
|
||||||
EOF
|
EOF
|
||||||
|
@ -387,7 +393,7 @@ EOF
|
||||||
cat <<EOF | sudo tee --append $qdr_conf_file
|
cat <<EOF | sudo tee --append $qdr_conf_file
|
||||||
log {
|
log {
|
||||||
module: DEFAULT
|
module: DEFAULT
|
||||||
enable: info+
|
enable: trace+
|
||||||
output: $log_file
|
output: $log_file
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue