So Im trying to run a cron job inside a docker container built with a simple dockerfile setup as an app platform. However, building is always successful but I always get a failed deployment due to a health check error and then the docker container is stopped. How can I disable this health check or preventing it from stopping the docker container? Or is there any other workaround or better solution? Thank you in advance
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Click below to sign up and get $100 of credit to try our products over 60 days!
Hello,
I believe that when creating your App component, you can specify the “Resource Type” to be a worker:
https://docs.digitalocean.com/products/app-platform/concepts/worker/
As workers can not accept HTTP requests, they are suitable for doing background tasks, just as in your usecase.
Hope that this helps!
Best,
Bobby
Hi @SandyBlueGreenRaft,
I don’t think that’s possible.
Having said that, most probably the issue is coming from something small. It can be some mismatched ports or something equally small. Take this question for example:
https://www.digitalocean.com/community/questions/app-platform-deploy-error-health-checks-deploycontainerhealthchecksfailed