Getting unavailable: 502 Bad Gateway when starting the runner in docker #600

Closed
opened 2024-09-12 17:59:58 +00:00 by schallbert · 1 comment
schallbert commented 2024-09-12 17:59:58 +00:00 (Migrated from gitea.com)

Hi!
I'm using act_runner a lot and I really, really appreciate the great work you did building this solution which I run as a lightweight alternative to GitLab's self-hosting variant 🥰.

I run Gitea behind a reverse proxy and everything as docker containers. Now, when I start Gitea, the runner will sometimes fail to instantiate - see my related blog post.

I was able to narrow the error down and figured out that when the runner started, Gitea wouldn't be ready yet so it couldn't "hook" onto Gitea. I solved that in my docker-compose.yml by adding not only the dependency, but a health check which runs a curl command repeatedly until Gitea is up and ready before starting the runner. Since then the services start without issues at all.

My proposal would be to update the docs accordingly (under act_runner/examples/docker-compose/README.md). I could prepare a PR, but first I wanted to check if anyone of you experienced similar issues (any if not, why).

Thank you so much
Schallbert

Hi! I'm using `act_runner` a lot and I really, really appreciate the great work you did building this solution which I run as a lightweight alternative to GitLab's self-hosting variant 🥰. I run Gitea behind a reverse proxy and everything as docker containers. Now, when I start Gitea, the runner will sometimes fail to instantiate - see my related [blog post](https://blog.schallbert.de/en/fix-gitea-runner/). I was able to narrow the error down and figured out that when the runner started, Gitea wouldn't be ready yet so it couldn't "hook" onto Gitea. I solved that in my `docker-compose.yml` by adding not only the dependency, but a health check which runs a `curl` command repeatedly until Gitea is up and ready before starting the runner. Since then the services start without issues at all. My proposal would be to update the docs accordingly (under `act_runner/examples/docker-compose/README.md`). I could prepare a PR, but first I wanted to check if anyone of you experienced similar issues (any if not, why). Thank you so much _Schallbert_
Zettat123 commented 2024-09-25 05:51:34 +00:00 (Migrated from gitea.com)

Hi @schallbert ! Thank you for delving into this issue. I didn't encounter this problem, but I reproduced it and successfully fixed it using the solution in your post. Therefore, I believe your solution works, and I think you could create a PR to update the documentation.

Hi @schallbert ! Thank you for delving into this issue. I didn't encounter this problem, but I reproduced it and successfully fixed it using the solution in your post. Therefore, I believe your solution works, and I think you could create a PR to update the documentation.
Sign in to join this conversation.