Skip to content

Instantly share code, notes, and snippets.

@damoclark
Forked from tdack/io.adafruit.com-bridge.conf
Last active December 15, 2016 00:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save damoclark/b182e6af0987be7e8130a22f1a8c34c9 to your computer and use it in GitHub Desktop.
Save damoclark/b182e6af0987be7e8130a22f1a8c34c9 to your computer and use it in GitHub Desktop.
Bridge Mosquitto MQTT broker to io.adafruit.com MQTT broker to use with io.adafruit.com
# Connection name
connection adafruit
# Secure SSL/TLS
address io.adafruit.com:8883
# adjust path as approriate to point to directory with PEM encoded .crt CA files
bridge_capath /etc/ssl/certs/
# For CentOS 7 (and other RHEL derivatives), use this directive instead of bridge_capath
# bridge_cafile /etc/ssl/certs/ca-bundle.crt
# Insecure
# address io.adafruit.com:1883
# Credentials
remote_username <your username>
remote_password <your aio key>
# Config options for bridge
start_type automatic
bridge_protocol_version mqttv311
# This is important, if set to True connection will fail,
# probably because users don't have permissions to $SYS/#
notifications false
# Also important. if set to True the connection will fail,
# it seems io.adafruit.com doesn't support this
try_private false
# Topics to bridge
# topic <local topic> <in|out|both> <QoS> <local topic prefix> <remote topic prefix>
# eg: bridge temperature/shed to temperature/shed
# topic temperature/shed out 0 "" ""
# eg: bridge to io.adafruit.com
# temperature/shed to <username>/feeds/temperature_shed
# topic shed out 0 temperature <username>/feeds/temperature_
# eg: bridge from io.adafruit.com
# <username>/feeds/throttle to adafruit.io/throttle
# topic throttle in 0 adafruit.io/ <username>/feeds/
#
# eg: bi-directional topic
# <username>/feeds/welcome-feed to/from adafruit.io/welcome-feed
# topic welcome-feed both 0 adafruit.io/ <username>/feeds/
# note: if using the Adafruit.io "Welcome Feed" you'll need to rename
# it to "welcome-feed" in the web interface for the above example to work
@damoclark
Copy link
Author

Just fixed a minor typo originally on line 10 (seems there needs to be a space after a hash to be a valid comment), and added bridge_cafile directive to point straight at the pem file as configured on typical RHEL derived GNU/Linux (I'm using CentOS7).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment