actions-runner-controller icon indicating copy to clipboard operation
actions-runner-controller copied to clipboard

The custom image of the runner is not used in the templates

Open GruemL opened this issue 1 year ago • 3 comments

Checks

  • [X] I've already read https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners-with-actions-runner-controller/troubleshooting-actions-runner-controller-errors and I'm sure my issue is not covered in the troubleshooting guide.
  • [X] I am using charts that are officially provided

Controller Version

0.9.3

Deployment Method

Helm

Checks

  • [X] This isn't a question or user support case (For Q&A and community support, go to Discussions).
  • [X] I've read the Changelog before submitting this issue and I'm sure it's not due to any recently-introduced backward-incompatible changes

To Reproduce

1. install helmchart for gha-runner-scale-set controller and gha-runner-scale set both in version 0.9.3
2. use the custom image path like its described in the [docs](https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners-with-actions-runner-controller/deploying-runner-scale-sets-with-actions-runner-controller#configuring-the-runner-image), but not provided in the [linked values.yaml](https://github.com/actions/actions-runner-controller/blob/master/charts/gha-runner-scale-set/values.yaml) and the [templates](https://github.com/actions/actions-runner-controller/tree/master/charts/gha-runner-scale-set/templates) of the helm chart.

we use it like this:


minRunners: 1
runnerGroup: "qs"
runnerScaleSetName: "ha-test"
template:
  spec:
    containers:
      - name: runner
        image: "IMAGE_PATH/NAME"
        imagePullPolicy: ifNotPresent
        command: ["/home/runner/run.sh"]
    imagePullSecrets:
      - name: SECRETNAME


There are no events or hints in the controller log. The runner pod does not start.

I know there is a discussion for this topic : https://github.com/actions/actions-runner-controller/discussions/2835

But it doesnt help for my problem.

Thank you in advance.

Describe the bug

The Bug is, that the customImage and ImagePullSecret Part from the docs is never used in the values.yaml or in one of the templates.

Or is the part for the listener pod that inherits the imagepullpolicy from the controller pod also valid for the runner pod?

Describe the expected behavior

I can use my custom image and imagepullsecret and it is used in values.yaml and templates like described in the docs.

Additional Context

values.yaml:


minRunners: 1
runnerGroup: "qs"
runnerScaleSetName: "ha-test"
template:
  spec:
    containers:
      - name: runner
        image: "IMAGE_PATH/NAME"
        imagePullPolicy: ifNotPresent
        command: ["/home/runner/run.sh"]
    imagePullSecrets:
      - name: SECRETNAME

Controller Logs

There are no errors in the controller pod logs

Runner Pod Logs

no runner pod is created - no events

GruemL avatar Sep 09 '24 09:09 GruemL

Hello! Thank you for filing an issue.

The maintainers will triage your issue shortly.

In the meantime, please take a look at the troubleshooting guide for bug reports.

If this is a feature request, please review our contribution guidelines.

github-actions[bot] avatar Sep 09 '24 09:09 github-actions[bot]

The secret with your private registry login is in the same namespace as the helm deployment (arc-runners by default)?

diegoara96 avatar Sep 12 '24 10:09 diegoara96

yes, it is in the same namespace. But there are no events that is even used.

GruemL avatar Sep 13 '24 07:09 GruemL

did you set the containerMode ?

This works

# ...
template:
  metadata:
    annotations:
      actions.github.com/ttl: "3600"
    labels:
      workload: arc-runners
  spec:
    nodeSelector:
      karpenter.sh/nodepool: arc-runners
    tolerations:
      - key: "workload"
        operator: "Equal"
        value: "arc-runners"
        effect: "NoSchedule"
    containers:
      - name: runner
        image: "<masked>.dkr.ecr.eu-west-1.amazonaws.com/actions-runner:${arc_image_version}"
        command: ["/home/runner/run.sh"]
        resources:
          requests:
            cpu: "8"
            memory: "32Gi"

containerMode:
  type: "dind"
# ...

busla avatar Jan 24 '25 07:01 busla

We have tests covering this case, and I'm failing to reproduce it. I will close this issue, but feel free to comment on it, and we can always re-open it.

nikola-jokic avatar Mar 27 '25 15:03 nikola-jokic