Sidekiq can't connect to redis on rails

I have my redis server installed and running, but when I connect sidekiq using bundle exec sidekiq , it gives an error message

Redis connection timeout on localhost: 6379

The Redis server runs on port: 6379.

+6
source share
3 answers

Why are you using bundle exec sidekiq?

Try connecting to "redis-cli -h localhost"

+1
source

I think this means that the redis server is not running. Try running sudo /etc/init.d/redis-server start on your terminal, also make sure that redis has write permission to /var/log/redis.log or it will not start.

0
source

For the question was my redis production url was wrong.

My fix:

  • open $ sudo nano gitlab/htdocs/config/resque.yml
  • change production: redis://some-wrong-url:6379 to production: redis://localhost:6379
  • restarted my Bitnami stack $ sudo /opt/bitnami/ctlscript.sh restart

First I confirmed my redis url from @henley's answer on the left.

* Note. I am using a Bitnami stack

0
source

All Articles