docs: def rmq_ssl_is_enabled_on_unit(self, sentry_unit, port=None):
          """Check a single juju rmq unit for ssl and port in the config file."""
          host = sentry_unit.info['public-address']
          unit_name = sentry_unit.info['unit_name']
  
          conf_file = '/etc/rabbitmq/rabbitmq.config'
          conf_contents = str(self.file_contents_safe(sentry_unit,
                                                      conf_file, max_wait=16))
          # Checks
          conf_ssl = 'ssl' in conf_contents
          conf_port = str(port) in conf_contents
  
          # Port explicitly checked in config
          if port and conf_port and conf_ssl:
              self.log.debug('SSL is enabled  @{}:{} '
                             '({})'.format(host, port, unit_name))
              return True
          elif port and not conf_port and conf_ssl:
              self.log.debug('SSL is enabled @{} but not on port {} '
                             '({})'.format(host, port, unit_name))
              return False
          # Port not checked (useful when checking that ssl is disabled)
          elif not port and conf_ssl:
              self.log.debug('SSL is enabled  @{}:{} '
                             '({})'.format(host, port, unit_name))
              return True
          elif not conf_ssl:
              self.log.debug('SSL not enabled @{}:{} '
                             '({})'.format(host, port, unit_name))
              return False
          else:
              msg = ('Unknown condition when checking SSL status @{}:{} '
                     '({})'.format(host, port, unit_name))
              amulet.raise_status(amulet.FAIL, msg)