LVKVLVS
Import code from parent directory
Thanks @Brody, that makes sense.
I've removed the root path and as a result Python is not detected as a provider (as expected).
I've added providers explicitly in railway.json file.
I've also added custom build command since requirements.txt is going to be nested in the child directory.
This is how my railway.json looks like:
{
"$schema": "https://railway.app/railway.schema.json",
"build": {
"builder": "NIXPACKS",
"buildCommand": "pip install -r job_queue/requirements.txt",
"nixpacksPlan": {
"providers": ["python"]
}
},
"deploy": {
"startCommand": "celery -A job_queue.worker.app worker --loglevel=INFO",
"restartPolicyType": "ON_FAILURE",
"restartPolicyMaxRetries": 3
}
}
However build still fails due to:
0.291 /bin/bash: line 1: pip: command not found
Could you help me out with this one as well? should I move this to nixpacks.toml file? if so which field would be required there to be added?
5 replies