Linux/Mosquitto: Difference between revisions

From Wiki
(Die Seite wurde neu angelegt: „* usage ** subscribe <blockquote> <pre> mosquitto_sub -t "test" mosquitto_sub -t "test" -u "username" -P "password" </pre> </blockquote> :* publish <blockquote…“)
 
No edit summary
Line 3: Line 3:
<blockquote>
<blockquote>
<pre>
<pre>
mosquitto_sub -t "test"
mosquitto_sub -t "test" -h servername
mosquitto_sub -t "test" -u "username" -P "password"
mosquitto_sub -t "test" -h servername -u "username" -P "password"
mosquitto_sub -t "test" -h servername -u "username" -P "password" -p 8883 --capath /etc/ssl/certs/
</pre>
</pre>
</blockquote>
</blockquote>
Line 10: Line 11:
<blockquote>
<blockquote>
<pre>
<pre>
mosquitto_pub -t "test" -m "message from client"  
mosquitto_pub -t "test" -m "test message" -h servername
mosquitto_pub -t "test" -m "message from client" -u "username" -P "password"
mosquitto_pub -t "test" -m "test message" -h servername -u "username" -P "password"
mosquitto_pub -t "test" -m "test message" -h servername -u "username" -P "password" -p 8883 --capath /etc/ssl/certs/
</pre>
</pre>
</blockquote>
</blockquote>

Revision as of 13:17, 2 September 2018

  • usage
    • subscribe
mosquitto_sub -t "test" -h servername
mosquitto_sub -t "test" -h servername -u "username" -P "password"
mosquitto_sub -t "test" -h servername -u "username" -P "password" -p 8883 --capath /etc/ssl/certs/
  • publish
mosquitto_pub -t "test" -m "test message" -h servername
mosquitto_pub -t "test" -m "test message" -h servername -u "username" -P "password"
mosquitto_pub -t "test" -m "test message" -h servername -u "username" -P "password" -p 8883 --capath /etc/ssl/certs/