Redis无法在macOS Sierra上运行

时间:2016-12-27 17:58:29

标签: macos redis rabbitmq macos-sierra

安装了rabbitmq服务器和docker之后,我尝试运行我的节点脚本,该脚本在本地主机上侦听端口6379上的kue用法,但我一直收到此错误:

    events.js:160
      throw er; // Unhandled 'error' event
      ^

Error: Redis connection to 127.0.0.1:6379 failed - connect ECONNREFUSED 127.0.0.1:6379
    at Object.exports._errnoException (util.js:1036:11)
    at exports._exceptionWithHostPort (util.js:1059:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1080:14)

我的rabbitmq在工作吗?是:

    ~rabbitmq-server

              RabbitMQ 3.6.4. Copyright (C) 2007-2016 Pivotal Software, Inc.
  ##  ##      Licensed under the MPL.  See http://www.rabbitmq.com/
  ##  ##
  ##########  Logs: /usr/local/var/log/rabbitmq/rabbit@localhost.log
  ######  ##        /usr/local/var/log/rabbitmq/rabbit@localhost-sasl.log
  ##########
              Starting broker...
 completed with 10 plugins

那么这里有什么问题?港口关闭了吗?如果是这样,我该怎么打开它?

1 个答案:

答案 0 :(得分:1)

我在github找到了答案... docker run --name redis -p 6379:6379 -d redis它现在有效..