-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Allow using factories with gitub repositories with the default branch that is not equal to "master" #18066
Conversation
✅ E2E Happy path tests succeed 🎉 See Details
Tested with Eclipse Che Multiuser User on K8S (minikube v1.1.1) |
✅ E2E Happy path tests succeed 🎉 See Details
Tested with Eclipse Che Multiuser User on K8S (minikube v1.1.1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we really need to evaluate the default branch here? Can't we just omit it?
❌ E2E Happy path tests failed ❗ See Details
Tested with Eclipse Che Multiuser User on K8S (minikube v1.1.1) ℹ️ |
I'm afraid that is unlikely possible. we always (if the branch is not set) looking for a devfile in the root of the Github repository. |
[ci-test] |
E2E tests of Eclipse Che Multiuser on OCP has failed: Use command [ci-test] to rerun the test. |
❌ E2E Happy path tests failed ❗ See Details
Tested with Eclipse Che Multiuser User on K8S (minikube v1.1.1) ℹ️ |
❌ E2E Happy path tests failed ❗ See Details
Tested with Eclipse Che Multiuser User on K8S (minikube v1.1.1) ℹ️ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general LGTM. Just some ideas to improvements and few questions.
...-factory-github/src/main/java/org/eclipse/che/api/factory/server/github/GithubURLParser.java
Outdated
Show resolved
Hide resolved
...-factory-github/src/main/java/org/eclipse/che/api/factory/server/github/GithubURLParser.java
Outdated
Show resolved
Hide resolved
...-factory-github/src/main/java/org/eclipse/che/api/factory/server/github/GithubURLParser.java
Outdated
Show resolved
Hide resolved
...re-api-factory-github/src/main/java/org/eclipse/che/api/factory/server/github/GithubUrl.java
Outdated
Show resolved
Hide resolved
...re-api-factory-github/src/main/java/org/eclipse/che/api/factory/server/github/GithubUrl.java
Outdated
Show resolved
Hide resolved
...re-api-factory-github/src/main/java/org/eclipse/che/api/factory/server/github/GithubUrl.java
Outdated
Show resolved
Hide resolved
Can't we simply use Like https://raw.githubusercontent.com/eclipse/che/HEAD/devfile.yaml Or with a repo with main branch: And omit branch in devfile if not specified ( so git clone use default as well) |
Nice, that would be much simpler. But don't we need the exact branch name later anyway? |
✅ E2E Happy path tests succeed 🎉 See Details
Tested with Eclipse Che Multiuser User on K8S (minikube v1.1.1) |
@sparkoo : if it's not specified by the user, no as Using |
will take a look. |
… that is not equal to master Signed-off-by: Sergii Kabashniuk <skabashniuk@redhat.com>
[crw-ci-test] |
✅ E2E Happy path tests succeed 🎉 See Details
Tested with Eclipse Che Multiuser User on K8S (minikube v1.1.1) |
I think this fix should be back-ported to 7.20.x as more and more ppl may face this issue in the near future |
What does this PR do?
Allow using factories with gitub repositories with the default branch that is not equal to "master"
To get a devfile content used @benoitf 's idea #18066 (comment)
Screenshot/screencast of this PR
What issues does this PR fix or reference?
Fixes #18044
How to test this PR?
Repo with default branch
main
quay.io/skabashn/che-server:che18044
che server imagehttps://che-che.apps.cluster-17ef.17ef.example.opentlc.com/f?url=https://github.com/skabashnyuk/TestMainBranch.git
main
Private or not existed GitHub repo
quay.io/skabashn/che-server:che18044
che server imagehttps://che-che.apps.cluster-17ef.17ef.example.opentlc.com//f?url=https://github.com/some/private.git
PR Checklist
As the author of this Pull Request I made sure that:
What issues does this PR fix or reference
andHow to test this PR
completedReviewers
Reviewers, please comment how you tested the PR when approving it.