diff --git a/templates/etc/mosquitto/mosquitto.conf.j2 b/templates/etc/mosquitto/mosquitto.conf.j2 index 2bdfd2f..679eb59 100644 --- a/templates/etc/mosquitto/mosquitto.conf.j2 +++ b/templates/etc/mosquitto/mosquitto.conf.j2 @@ -1,11 +1,4 @@ -# Config file for mosquitto -# -# See mosquitto.conf(5) for more information. -# -# Default values are shown, uncomment to change. -# -# Use the # character to indicate a comment, but only if it is the -# very first character on the line. +# {{ ansible_managed }} # ================================================================= # General configuration @@ -210,7 +203,7 @@ port {{ mosquitto_port }} # capath defines a directory that will be searched for files # containing the CA certificates. For capath to work correctly, the # certificate files must have ".crt" as the file ending and you must run -# "openssl rehash " each time you add/remove a certificate. +# "openssl rehash /path/to/capath" each time you add/remove a certificate. #cafile capath {{ mosquitto_ca_path }} @@ -364,7 +357,7 @@ capath {{ mosquitto_ca_path }} # capath defines a directory that will be searched for files # containing the CA certificates. For capath to work correctly, the # certificate files must have ".crt" as the file ending and you must run -# "openssl rehash " each time you add/remove a certificate. +# "openssl rehash /path/to/capath" each time you add/remove a certificate. #cafile #capath @@ -475,7 +468,7 @@ persistence_location {{ mosquitto_persistence_path | dirname }} # syslog uses the userspace syslog facility which usually ends up # in /var/log/messages or similar. # -# topic logs to the broker topic '$SYS/broker/log/', +# topic logs to the broker topic '$SYS/broker/log/severity', # where severity is one of D, E, W, N, I, M which are debug, error, # warning, notice, information and message. Message type severity is used by # the subscribe/unsubscribe log_types and publishes log messages to @@ -576,18 +569,18 @@ persistence_location {{ mosquitto_persistence_path | dirname }} # comment. # Topic access is added with lines of the format: # -# topic [read|write|readwrite] +# topic [read|write|readwrite] 'topic' # # The access type is controlled using "read", "write" or "readwrite". This -# parameter is optional (unless contains a space character) - if not -# given then the access is read/write. can contain the + or # +# parameter is optional (unless 'topic' contains a space character) - if not +# given then the access is read/write. 'topic' can contain the + or # # wildcards as in subscriptions. # # The first set of topics are applied to anonymous clients, assuming # allow_anonymous is true. User specific topic ACLs are added after a # user line as follows: # -# user +# user 'username' # # The username referred to here is the same as in password_file. It is # not the clientid. @@ -610,7 +603,7 @@ persistence_location {{ mosquitto_persistence_path | dirname }} # with the following pattern: # pattern write $SYS/broker/connection/%c/state # -# pattern [read|write|readwrite] +# pattern [read|write|readwrite] 'topic' # # Example: # @@ -682,9 +675,9 @@ persistence_location {{ mosquitto_persistence_path | dirname }} # subscription for the old topic. If you have this problem, connect your bridge # with cleansession set to true, then reconnect with cleansession set to false # as normal. -#connection -#address [:] [[:]] -#topic [[[out | in | both] qos-level] local-prefix remote-prefix] +#connection 'name' +#address host[:port] [host[:port]] +#topic 'topic' [[[out | in | both] qos-level] local-prefix remote-prefix] # Set the version of the MQTT protocol to use with for this bridge. Can be one # of mqttv311 or mqttv11. Defaults to mqttv311. @@ -718,7 +711,7 @@ persistence_location {{ mosquitto_persistence_path | dirname }} #remote_clientid # Set the clientid to use on the local broker. If not defined, this defaults to -# 'local.'. If you are bridging a broker to itself, it is important +# 'local.clientid'. If you are bridging a broker to itself, it is important # that local_clientid and clientid do not match. #local_clientid @@ -734,7 +727,7 @@ persistence_location {{ mosquitto_persistence_path | dirname }} # If set to true, publish notification messages to the local and remote brokers # giving information about the state of the bridge connection. Retained -# messages are published to the topic $SYS/broker/connection//state +# messages are published to the topic $SYS/broker/connection/clientid/state # unless the notification_topic option is used. # If the message is 1 then the connection is active, or 0 if the connection has # failed. @@ -742,7 +735,7 @@ persistence_location {{ mosquitto_persistence_path | dirname }} # Choose the topic on which notification messages for this bridge are # published. If not set, messages are published on the topic -# $SYS/broker/connection//state +# $SYS/broker/connection/clientid/state #notification_topic # Set the keepalive interval for this bridge connection, in @@ -811,7 +804,7 @@ persistence_location {{ mosquitto_persistence_path | dirname }} # bridge_capath defines a directory that will be searched for files containing # the CA certificates. For bridge_capath to work correctly, the certificate # files must have ".crt" as the file ending and you must run "openssl rehash -# " each time you add/remove a certificate. +# /path/to/capath" each time you add/remove a certificate. #bridge_cafile #bridge_capath