This is MUSCLE - A Mosquitto ACL manager with REST APIs and dashboard. |View on Github|
- Install Ruby on your system
- run ./tools-install-dependencies.sh
- run ./tools-start-server.sh [port]
- Install Ruby on your system
- Install Sinatra using
gem install sinatra
- Install Sinatra-CORS using
gem install sinatra-cors
- Install Awesome Print using
gem install awesome_print
- Configure the credentials by editing the file
muscleconf.json
- Run the server using
ruby app.rb
- Go to the link http://{hostname}:9292 (hostname=localhost/machineIP) and enter the credentials to check everything is working
- View the example Mosquitto configuration file - config-templates/mosquitto.conf.template
- Either copy the above file into /etc/mosquitto/mosquitto.conf or modify your own configuration file accordingly.
- View the muscleconf.json file which contains the login credentials for consuming the REST APIs and the dashboard. Modify accordingly.
- Start Mosquitto MQTT Broker service is on your system - service mosquitto restart | systemctl restart mosquitto
- Check is Mosquitto MQTT Broker service is running - service mosquitto status | systemctl restart status
- "/" - point your browser to the root of the server e.g http://localhost:9292 (default)
- "/login" - parameters in urlencoded format -> uname and passwd e.g uname=paul&passwd=dirac (default)
- "/login" - returns true if you are logged in, else false
- "/users"
- "/acls"
- "/user/{username}/{password}"
- "/acl/{username}/{topic}/{access(read/write/readwrite)}"
- "/user/{username}"
- "/acls/{username}/{topic}"
- "/sighup"