315e56ae2b
As far as we use redis as a name service we don't need a proxy, becase we can pass binded port over name service too. Change-Id: I59bbe2b34dcedfeef113ef06d6a988e1c413405e
26 lines
467 B
Bash
Executable File
26 lines
467 B
Bash
Executable File
#!/bin/bash
|
|
set -e
|
|
|
|
. tools/functions.sh
|
|
|
|
DATADIR=$(mktemp -d /tmp/OSLOMSG-ZEROMQ.XXXXX)
|
|
trap "clean_exit $DATADIR" EXIT
|
|
|
|
export TRANSPORT_URL=zmq://
|
|
export ZMQ_MATCHMAKER=redis
|
|
export ZMQ_REDIS_PORT=65123
|
|
export ZMQ_IPC_DIR=${DATADIR}
|
|
|
|
cat > ${DATADIR}/zmq.conf <<EOF
|
|
[DEFAULT]
|
|
transport_url=${TRANSPORT_URL}
|
|
rpc_zmq_matchmaker=${ZMQ_MATCHMAKER}
|
|
rpc_zmq_ipc_dir=${ZMQ_IPC_DIR}
|
|
[matchmaker_redis]
|
|
port=${ZMQ_REDIS_PORT}
|
|
EOF
|
|
|
|
redis-server --port $ZMQ_REDIS_PORT &
|
|
|
|
$*
|