2 years ago
I deployed my Celery Task using Railway with Redis as the broker. It works on localhost, but it doesn't work on the staging environment.My railway.toml file.
[build]
builder = "NIXPACKS"
buildCommand = "echo building!"
[deploy]
runtime = "UNSPECIFIED"
numReplicas = 1
startCommand = "gunicorn setup.wsgi.test_wsgi --log-file - && celery -A setup worker -l INFO"
sleepApplication = true
restartPolicyType = "ON_FAILURE"
restartPolicyMaxRetries = 109 Replies
2 years ago
Could you share more details, please? What isn't working?
It's also highly likely that this is an issue with your application, not the Railway platform. Unfortunately we're unable to provide help for application-specific issues -- I'd recommend checking out other communities such as https://stackoverflow.com/ for general programming-related questions.
2 years ago
Yep this is an issue with your config, you are wanting to run gunicorn and celery meaning you need two Railway services, one service will run gunicorn and one service will run celery.
2 years ago
Yep this is an issue with your config, you are wanting to run gunicorn and celery meaning you need two Railway services, one service will run gunicorn and one service will run celery.
So how do i structure it, to make it work?
2 years ago
Could you share more details, please? What isn't working?
It's also highly likely that this is an issue with your application, not the Railway platform. Unfortunately we're unable to provide help for application-specific issues -- I'd recommend checking out other communities such as https://stackoverflow.com/ for general programming-related questions.
The tasks are not running.
2 years ago
Please read my message and make the changes I suggested.
Noted Chief, I'll do that
7 months ago
Hey brody I have done exactly like that two services for gunicorn and celery but still the celery part connected to redis and also the gunicorn is connected doesn't listen to async requests