sardinasystems/fleeting-plugin-openstack

Is gitlab-runner necessary in the worker VM image?

Closed this issue · 3 comments

The README says

You should upload a special image with gitlab-runner and container runtime installed in it.

We are using an image for the worker VMs which does not have the gitlab-runner package installed, and don't see any obvious misbehaviour as a result. The GitLab docs https://docs.gitlab.com/runner/executors/docker_autoscaler.html#configure-docker-autoscaler don't mention the requirement either. What situations require gitlab-runner to be installed in the workers? What things should we watch out for if we don't have gitlab-runner in the VM image? Thanks!

I'm not sure, perhaps something was changed over time. But earlier version works as follows:

  • manager VM polls for jobs, also maintain autoscaler engine, which bring your workers
  • once manager accept some job, it pass it over SSH to a gitlab-runner inside worker VM
  • for later comms manager runner acts as a proxy to worker runner (e.g. console log)
  • worker's runner communicate to docker/podman/cri/whatever

One of idea, they probably just pulls runner as docker image too. Older code simply starts runner via SSH. So why not to use container infra for that?

Just as advise try to setup caching registry proxy.

@davebiffuk i had some time to see and test new things. So I can prove that now only container runtime is necessary on worker.
More over i took special container linux, a Flatcar, and recreated whole farm. Gitlab Runner container runs on the manager node, then just connects to remove docker.sock via SSH.

https://github.com/sardinasystems/fleeting-plugin-openstack/tree/main/heat