#!/bin/bash ROOT=$(cd `dirname $0`/../../; pwd) TOPIC=test URL=http://127.0.0.1:9051/mpub?topic=$TOPIC echo url: $URL for m in `cat ./msgs.txt` do MSG="$MSG|$m" done echo MSGS: $MSG curl -d "$MSG" $URL