Installing Mosquitto on MacOS
Mosquitto is installed via homebrew
If you don't have homebrew already:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
Install Mosquitto:
brew install mosquitto
Verify that mosquitto broker can be started ( not give command not found):
mosquitto
If you get command not found run the following and restart console:
echo 'export PATH="/usr/local/sbin:$PATH"' >> ~/.bash_profile
Homebrew installs the broker, client binaries in:
- /usr/local/opt/mosquitto/bin/mosquitto_pub
- /usr/local/opt/mosquitto/bin/mosquitto_sub
- /usr/local/sbin/mosquitto (the broker)
The default conf file is in -c /usr/local/etc/mosquitto/mosquitto.conf