1

I connected my existing kubernetes cluster to gitlab using the gitlab integration in myproject/operations/kubernetes on the left tab pane in the gitlab gui.

After having installed helm + gitlab runner from the gitlab GUI applications, the new gitlab runner is visible in the project runners.

What I don't understand from the gitlab documentation is how do you modify the new runner's configuration. You cannot use the gitlab-runner cli, like for a non-kubernetes runner, because the runner in running in a pod, not on the host machine, right?

I am not sure which part of the runner doc applies to my case. What to use if I wanted to make the runner use another executor or build from another image ? (default image of the pod is ubuntu 16 for me).

If you have already installed and configured a runner installed this way, from the GUI, please tell me how. Thank you.

Gitlab 12.9.2 hosted

1 Answer 1

1

Installing kubernetes integration on gitlab

In Admin Area -> Overview -> Runners, the instructions they give are:

  1. Install GitLab Runner
  2. Specify the following URL during the Runner setup: https://<your gitlab hostname>/
  3. Use the following registration token during setup: <insert-token-here>
  4. Start the Runner!

I'm on version 13.13.0 but I don't remember the instructions changing from version 12.x.x.

Project specific runners

As for your question regarding configuration, I'm a little bit confused if you're looking for something beyond those instructions. If you want to set up a runner specific to a project, you can go to a project then navigate to Settings -> CI/CD -> Runners -> Specific Runners. There, there are more instructions on setting up project-specific runners.

Further configuring the runner

EDIT: The executor entirely depends on how the runner itself is installed. If it's installed on a kubernetes cluster, then it must be the kubernetes executor. That will affect your pipeline. I think you can create another one if you install another one with the runner chart. You can also use Helm Tiller.

7
  • Thanks, this I already did. What I don't understand it how to further configure the runner, e.g. change its executor (docker, shell, virtualbox...) or change the image it uses (default is ubuntu 16)
    – NanoPish
    Dec 16, 2020 at 16:41
  • also, gitlab created one runner. what if I wanted a second one ? am I missing something in the GUI?
    – NanoPish
    Dec 16, 2020 at 16:51
  • 1
    Oh, I think the executor entirely depends on how the runner itself is installed. If it's installed on a kubernetes cluster, then it must be the kubernetes executor. That will affect your pipeline. I think you can totally create another one if you install another one with the runner chart. You can also use Helm Tiller. Dec 16, 2020 at 16:56
  • thanks I will try configuring the runner with chart or helm then ! add your comment to the answer so I can accept it
    – NanoPish
    Dec 16, 2020 at 17:02
  • 1
    One thing I might add to your question are the comments you sent to me about the runner executor. Dec 16, 2020 at 17:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.