webdevops / Dockerfile

:package: Dockerfiles from WebDevOps for PHP, Apache and Nginx
https://webdevops.io/projects/dockerfiles/
MIT License
1.65k stars 487 forks source link

google cloud run 503 error #462

Open iBasit opened 1 year ago

iBasit commented 1 year ago

Following the google hello world example, the PHP code works smoothly instantly.

However, if we use a similar version of PHP webdevops image "webdevops/php-apache:8.0" or any other version, on the first initial call, we get 503 apache service unavailable error, then on refresh, the application starts working as expected.

I'm not sure what is causing this issue but I have tried every possible thing to fix it (raising memory, CPU...)

emresavas commented 1 year ago

Please see cold start section on cloudrun docs here. During the first start of container, if services not start in 10 seconds, cloudrun does not keep requests pending. That's why you see it on second reload but not initially.