Uploaded image for project: 'AMQ Broker'
  1. AMQ Broker
  2. ENTMQBR-8211

[Docs] Cannot connect to AMQ broker with mqtt protocol

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Undefined Undefined
    • None
    • None
    • documentation
    • False
    • None
    • False

      I am evaluating AMQ broker with mqtt protocol. I want to expose the broker so that it can be accessible externally.

      I followed the official document to configure it. the ActiveMQArtemis instance spec likes

       

      acceptors:
       - connectionsAllowed: 5
       expose: true
       name: my-acceptor
       port: 1883
       protocols: mqtt 

      I cannot connect externally by using `mosquitto_pub -d --insecure -t "test" -m "test" -u admin -P admin -h ex-aao-my-acceptor-0-svc-rte-default.xxx.red-chesterfield.com -p 443 --cafile openshift_root_ca`

      Thanks dbruscin point me that I need to enable ssl.

      Then I follow document to create one-way tls.

      the ActiveMQArtemis instance spec likes

      acceptors:
       - connectionsAllowed: 5
       expose: true
       name: my-acceptor
       port: 1883
       protocols: mqtt
       sslEnabled: true
       sslSecret: my-tls-secret

      I cannot connect externally by using `mosquitto_pub -d --insecure -t "test" -m "test" -u admin -P admin -h ex-aao-my-acceptor-0-svc-rte-default.xxx.red-chesterfield.com -p 443 --cafile broker_cert.pem`. Unable to connect (A TLS error occurred.).

      the broker_cert.pem is wrong. the broker_cert.pem is generated by following the above document.

      How to create a correct cert file to access the broker?

       

            jcliffor@redhat.com John Clifford
            clyang82 Chunlin Yang
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: