-
Notifications
You must be signed in to change notification settings - Fork 341
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
CML initialization is broken on GH in container mode #970
Comments
minimal example: name: test cml ci
on:
push:
workflow_dispatch:
jobs:
test-v2:
runs-on: ubuntu-latest
container: ghcr.io/iterative/cml:latest
steps:
- uses: actions/checkout@v2
- run: cml ci
test-v3:
runs-on: ubuntu-latest
container: ghcr.io/iterative/cml:latest
steps:
- uses: actions/checkout@v3
- run: cml ci
test-setup-v2:
runs-on: ubuntu-latest
steps:
- uses: iterative/setup-cml@v1
- uses: actions/checkout@v2
- run: cml ci
test-setup-v3:
runs-on: ubuntu-latest
steps:
- uses: iterative/setup-cml@v1
- uses: actions/checkout@v3
- run: cml ci https://github.com/dacbd/err/actions/runs/2182120620 test-v2 / test-v3 fail with an error:
when I expect them to complain with same |
Also (/CC @iterative/cml) think we recommend |
Yes, |
Order doesn't matter, unless |
Infimum exampleon: workflow_dispatch
jobs:
succeeds:
runs-on: ubuntu-latest
steps:
- uses: iterative/setup-cml@v1
- uses: actions/checkout@v3
- run: cml ci
env:
GITHUB_TOKEN: ${{ github.token }}
fails:
runs-on: ubuntu-latest
container: ghcr.io/iterative/cml
steps:
- uses: actions/checkout@v3
- run: cml ci
env:
GITHUB_TOKEN: ${{ github.token }} |
FixRunning on: push
jobs:
fix:
runs-on: ubuntu-latest
container: ghcr.io/iterative/cml
steps:
- uses: actions/checkout@v3
- run: git config --global --add safe.directory "$PWD"
- run: cml ci
env:
GITHUB_TOKEN: ${{ github.token }} |
@iterative/cml & company, what option do you prefer?
|
@0x2b3bfa0 are there other way to get the same result as |
Yes, see the
It's rather the first thing that is failing. Any fatal: unsafe repository ('/path/to/repository' is owned by someone else)
To add an exception for this directory, call:
git config --global --add safe.directory /path/to/repository
I'd wish! 😅 We use many other |
Got it. How does CI works in general now if any git is failing? Does it mean that it'll be fixed by GH soon? Or is it specific to the way action checkout does things?
Seems unreliable - we'll have to deal with this in the non-container mode now or soon? One more option - can we make it part of CML init? |
This comment was marked as outdated.
This comment was marked as outdated.
It works fine everywhere, except for containers, where there is a mismatch between the owner of the cloned repository and the user running the commands: actions/checkout#47 (comment)
It will probably be fixed by GitHub, and it's specific to the
If you mean setting |
Right, thanks for clarifying this one more time, Helio.
Yes, part of every command. Not exactly option 2 if I understand it right, since |
Absolutely! 💯 |
Highlights from Git 2.36
|
Basic CML workflow like this is broken.
I'm getting:
Command
git config --get remote.origin.url
that is triggered in CML ctr fails.Most likely this is due to some breaking changes in action checkout (v2 and v3 both affected). They have recently had to upgrade those due to recent update of Git on GH https://github.blog/2022-04-12-git-security-vulnerability-announced/
(more info for the reference is here: https://iterativeai.slack.com/archives/C01900GSB4J/p1650245948446699 (internal link))
The text was updated successfully, but these errors were encountered: