Paid Redis not connecting to Rails Worker

I believe this issue started when I upgraded from a Free Redis to the Paid Redis when making a new app. I copied all config from a previously working Fly V2 backend of mine.

Been trying to resolve this issue for a few days, found these topics, but they were closed to replies:

The Sidekiq dashboard shows the correct Redis url.

  • Sidekiq v7.0.9
  • redis://

fly redis connect works fine from local.

fly ssh console -C "printenv" also shows the correct url.

You can see the correct url in the dashboard monitoring logs.

You can enqueue items, but they never fire.

I’ve tried dozens of variations of both V1 and V2 style toml configs, super simple or complex and also changing the web process to app process, but seeing no difference in behavior.

Here is latest:

app = "api-x"
primary_region = "mia"
kill_signal = "SIGINT"
kill_timeout = "5s"
console_command = "/rails/bin/rails console"

auto_rollback = true
autoscale = true

min = 1
max = 10

BUILD_COMMAND = "bin/rails fly:build"
NODE_VERSION = "17.2.0"
RUBY_VERSION = "3.1.2"
SERVER_COMMAND = "bin/rails fly:server"

release_command = "bundle exec rails db:migrate"

PORT = "8080"

web = "bin/rails fly:server"
worker = "bundle exec sidekiq --verbose"

protocol = "tcp"
internal_port = 8080
processes = ["web"]

port = 80
handlers = ["http"]
force_https = true

port = 443
handlers = ["tls", "http"]
type = "connections"
hard_limit = 100
soft_limit = 90

interval = "15s"
timeout = "2s"
grace_period = "1s"
restart_limit = 0

guest_path = "/app/public"
url_prefix = "/"


require "sidekiq"
require "sidekiq/web"
require "sidekiq-scheduler"
require "sidekiq-scheduler/web"

Sidekiq.configure_server do |config|
  config.redis = { url: ENV["REDIS_URL"] }

Sidekiq.configure_client do |config|
  config.redis = { url: ENV["REDIS_URL"] }

Any ideas?

Can you check your logs with fly logs? That should give you a hint as to what’s going on. I noticed your org registered some OOMs, meaning one of your processes has run out of memory, Maybe that’s related.

I scaled up the apps, but not their workers, should they be equal in size? Though apps that haven’t been deployed recently that were using free redis, their sidekiq queues now also show up within the new / paid redis instance, yet they still hang for days on end.

Neither apps can actually get the queue to fire though.

The only way to get 1 job to process is to manually run:

flyctl ssh console -C 'bundle exec sidekiq' -a app-name

But the actual worker itself, seems to never do anything.

Haven’t been able to get logs from the worker, because it never Starts up.

I think the best thing here is to check your logs while the instances are being deployed. That should give you some information about what’s happening.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.