vegardit / docker-gitea-act-runner

Docker image based on debian:stable-slim to run Gitea's act_runner as a Docker container

Home Page:https://buymeacoffee.com/vegardit

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

GITEA_RUNNER_JOB_CONTAINER_OPTIONS causes network a issue

Yedrimas opened this issue · comments

Using image : vegardit/gitea-act-runner:dind-latest
And compose :

  gitearunner:
    container_name: runner1
    image: vegardit/gitea-act-runner:dind-latest
    depends_on:
      - gitea
    privileged: true
    restart: unless-stopped
    networks:
      gitea-external:
      gitea-internal:
    environment:
      GITEA_RUNNER_JOB_CONTAINER_OPTIONS: --add-host=gitea:172.0.1.5  --volume /repo:/repo
      GITEA_RUNNER_JOB_CONTAINER_PRIVILEGED: true
      TZ: Europe/PARIS
      GITEA_INSTANCE_URL: http://gitea:3000
      GITEA_RUNNER_REGISTRATION_TOKEN: [very secret token]
    volumes:
      - /gitea/runner1:/data:rw
      - /etc/repo:/repo

The latest update causes the Set up job in Gitea to fail with : Error response from daemon: container sharing network namespace with another container or host cannot be connected to any other network
When removing the GITEA_RUNNER_JOB_CONTAINER_OPTIONS or setting it to empty; the issue vanishes.
I've tried modifying the content of the variable to only mount the volume or the --add-host, but the issue is still present.

This was not the case in previous version(s) of this image.
(Don't mind the weird, --add-host value)

This sounds like a bug in the act-runner itself. You may need to open an issue here https://gitea.com/gitea/act_runner/issues

I'm wondering if this could be linked to https://gitea.com/gitea/act_runner/commit/35596a182b61992b1f4db5172a7982a055c55453
where network_mode was deprecated and replaced by network.
So a modification might be needed on config.template.yaml

AFAIK that commit is not yet in a release. This docker image uses the latest released version, which is currently https://dl.gitea.com/act_runner/0.1.8

Will do, it indeed seems that it comes from the runner itself. Thanks !