Skip to content

workspace for jobs uses repo/repo instead of org/repo #1074

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

Open
na4ma4 opened this issue May 5, 2021 · 6 comments · May be fixed by #1075
Open

workspace for jobs uses repo/repo instead of org/repo #1074

na4ma4 opened this issue May 5, 2021 · 6 comments · May be fixed by #1075
Labels
bug Something isn't working Runner Bug Bug fix scope to the runner

Comments

@na4ma4
Copy link

na4ma4 commented May 5, 2021

Describe the bug

The workspace for the job is repo/repo not org/repo, while using self-hosted runners on github.com with a single organisation that is fine, but against enterprise there may be multiple orgs with the same repo name that are used by the same runners.

Example: /home/ubuntu/actions-runner/_work/actions-test/actions-test instead of /home/ubuntu/actions-runner/_work/testorg/actions-test

Runner Version and Platform

Version of your runner? 2.273.5

OS of the machine running the runner? Ubuntu 20.04.2 LTS

@na4ma4 na4ma4 added the bug Something isn't working label May 5, 2021
@TingluoHuang
Copy link
Member

repo/repo: the first repo is for which repo the workflow is coming from, the second repo is for the repository you checkout.

you can use actions/checkout to checkout multiple repositories in a single job, then you will get the following on disk:

repo/repo
repo/repo1
repo/repo2

@na4ma4
Copy link
Author

na4ma4 commented May 5, 2021

would it make more sense then to go org/repo/(checkout)repo ?

like:

org/repo/repo
org/repo/repo1
org/repo/repo2

@na4ma4
Copy link
Author

na4ma4 commented May 5, 2021

I'm not sure actions/checkout works that way with the GHES and the self-hosted runner.

I've tried putting a second actions/checkout step in and with just the repository parameter, it just overwrote the _work/repo/repo directory, I tried adding a path parameter, and it just checked it out in _work/repo/repo/path

@na4ma4
Copy link
Author

na4ma4 commented May 5, 2021

Seems to work the same way in github.com hosted runners, the working directory is repo/repo and actions/checkout does repo/repo/repo1.

I did some testing with a self-hosted runner and a cloud runner.

@nikola-jokic nikola-jokic added the Runner Bug Bug fix scope to the runner label Apr 4, 2022
@jenergm
Copy link

jenergm commented Jan 5, 2024

We have the same problem in our projects with large repository names. We're using GitHub EMU. I think better for everyone is you can set a work folder in the "on runner" statements. And we can chose a name that works to the project and don't have a large path that damages your build. Lots of our repository builds doesn't work because that.

Where was "repo/repo/" could be "s/" for example.

@na4ma4
Copy link
Author

na4ma4 commented Aug 4, 2024

I wonder if it would be better to just be a uuid (eg. 6b4ac2f5-7b3d-43b1-b9b0-f336e5e74bff/)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Runner Bug Bug fix scope to the runner
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants