Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DIND gha-runner-scale-set: cp: cannot stat '/home/runner/externals/.': No such file or directory #3634

Open
4 tasks done
rdvansloten opened this issue Jul 2, 2024 · 6 comments · May be fixed by #3740
Open
4 tasks done
Labels
bug Something isn't working gha-runner-scale-set Related to the gha-runner-scale-set mode needs triage Requires review from the maintainers

Comments

@rdvansloten
Copy link

Checks

Controller Version

0.9.3

Deployment Method

Helm

Checks

  • This isn't a question or user support case (For Q&A and community support, go to Discussions).
  • 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

- Install latest oci://ghcr.io/actions/actions-runner-controller-charts/gha-runner-scale-set
- Watch as "init-dind-externals" errors out with cp: cannot stat '/home/runner/externals/.': No such file or directory

Describe the bug

Expected my init-dind-externals to work.

Describe the expected behavior

init-dind-externals should start, so that my runner can.

Additional Context

Using this Dockerfile build from the main branch of the repo:
actions-runner-dind.ubuntu-22.04.dockerfile

Passing this values file, straight from the docs, with edits where needed. The images are from my private registry, since our firewall doesn't allow remote pull. I imported/built official Dockerfiles from the repo, or pulled straight from ghcr. I built/imported everything for 0.9.3 today.


githubConfigUrl: "https://github.com/my-company"
githubConfigSecret:
  github_token: "redacted"

runnerGroup: "redacted"

template:
  spec:
    initContainers:
      - name: init-dind-externals
        image: redacted.azurecr.io/actions/actions-runner:latest
        command:
          ["cp", "-r", "-v", "/home/runner/externals/.", "/home/runner/tmpDir/"]
        volumeMounts:
          - name: dind-externals
            mountPath: /home/runner/tmpDir
    containers:
      - name: runner
        image: redacted.azurecr.io/actions/actions-runner:latest
        command: ["/home/runner/run.sh"]
        env:
          - name: DOCKER_HOST
            value: unix:///var/run/docker.sock
        volumeMounts:
          - name: work
            mountPath: /home/runner/_work
          - name: dind-sock
            mountPath: /var/run
      - name: dind
        image: redacted.azurecr.io/library/docker:26.1.4-dind
        args:
          - dockerd
          - --host=unix:///var/run/docker.sock
          - --group=$(DOCKER_GROUP_GID)
        env:
          - name: DOCKER_GROUP_GID
            value: "123"
        securityContext:
          privileged: true
        volumeMounts:
          - name: work
            mountPath: /home/runner/_work
          - name: dind-sock
            mountPath: /var/run
          - name: dind-externals
            mountPath: /home/runner/externals
    volumes:
      - name: work
        emptyDir: {}
      - name: dind-sock
        emptyDir: {}
      - name: dind-externals
        emptyDir: {}


### Controller Logs

```shell
Controller has no opinion about a crashing init container.

Runner Pod Logs

`cp: cannot stat '/home/runner/externals/.': No such file or directory`
@rdvansloten rdvansloten added bug Something isn't working gha-runner-scale-set Related to the gha-runner-scale-set mode needs triage Requires review from the maintainers labels Jul 2, 2024
Copy link
Contributor

github-actions bot commented Jul 2, 2024

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.

@umaasik
Copy link

umaasik commented Jul 5, 2024

I'm running into the same issue using rootless images.

@aaronmassicotte
Copy link

aaronmassicotte commented Jul 12, 2024

Same boat here, on 0.9.2. It's odd because this is only occurring on one of 3 runnersets, all using the same helm chart and cluster

@claytonchew claytonchew linked a pull request Sep 12, 2024 that will close this issue
@claytonchew
Copy link

Submitted a fix (#3740) for this.

@AurimasNav
Copy link

I'm encountering this when trying to use values.yaml to specify my runner image:

template:
  spec:
    containers:
    - name: runner
      image: private-repo.com/actions-runner:latest
      command: ["/home/runner/run.sh"]

which is built using Dockerfile:

FROM summerwind/actions-runner:latest

USER root

RUN echo 'APT::Install-Suggests "0";' >> /etc/apt/apt.conf.d/00-docker
RUN echo 'APT::Install-Recommends "0";' >> /etc/apt/apt.conf.d/00-docker

RUN <<EOF
. /etc/os-release
wget -q https://packages.microsoft.com/config/ubuntu/$VERSION_ID/packages-microsoft-prod.deb
dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
DEBIAN_FRONTEND=noninteractive
apt-get update
apt-get install -y -qq powershell
EOF

USER runner

@AurimasNav
Copy link

problem went away when using ghcr.io/actions/actions-runner:latestas base image instead of summerwind/actions-runner:latest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working gha-runner-scale-set Related to the gha-runner-scale-set mode needs triage Requires review from the maintainers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants