1

im having trouble with running celery as a daemon on ubuntu.

I have run the debug command as suggested in the documentation http://docs.celeryproject.org/en/latest/userguide/daemonizing.html#example-configuration (troubleshooting section)

sh -x /etc/init.d/celeryd start

and the last line of the output looks like it changes to the celery user and tries to run the file

su celery -c /home/ubuntu/.local/bin/celery

so I logged in as the celery user and just tried to run that file to test

celery@ip-10-10-10-1:/$ /home/ubuntu/.local/bin/celery
-su: /home/ubuntu/.local/bin/celery: Permission denied
celery@ip-10-10-10-1:/$ groups
users grp_celery

I give the celery group ownership of that file

-rwxrwxrwx 1 celery grp_celery 216 Apr 11 12:05 /home/ubuntu/.local/bin/celery

but it still cannot access it. can anyone help me out?

Thanks

AlexW
  • 13
  • 2

1 Answers1

0

Disclaimer - I have never configured celery.

I would bet that you are running into permissions issues at a parent directory that is preventing it from traversing down to that file. You should be able to test this easily by trying to cd to each level of that path as the celery user and seeing where it fails.

Now you 'could' allow the celery user all the way in... but a better approach might be to move the config files outside of the ubuntu user's home directory. Again, that depends on what is needed from the celery config... which I have not previously configured.