TrafeX / docker-php-nginx

Docker image with PHP-FPM 8.3 & Nginx 1.26 on Alpine Linux
https://hub.docker.com/r/trafex/php-nginx
MIT License
1.39k stars 738 forks source link

Cron? #27

Closed bpuig closed 4 years ago

bpuig commented 4 years ago

Any idea of how to run cron in supervisord in this dockerfile? I'm hitting a wall here...

Tried this with no success:

[program:cron]
command = /usr/sbin/crond -f -l 15
autostart=true
autorestart=true
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0

Thanks

bpuig commented 4 years ago

I think it's related to not being able to run cron as non-root. I found this: https://github.com/aptible/supercronic and it works