-
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
Provision git configuration into each container #14402
Conversation
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has failed:
|
E2E tests of Eclipse Che Multiuser on OCP has failed:
|
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
E2E tests of Eclipse Che Multiuser on OCP has failed:
|
String userId = EnvironmentContext.getCurrent().getSubject().getUserId(); | ||
Map<String, String> preferencesMap = preferenceManager.find(userId, keyFilter); | ||
|
||
return ofNullable(preferencesMap.get(PREFERENCES_KEY_FILTER)); |
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.
This function is a bit odd for me. It is a private function that is used with PREFERENCES_KEY_FILTER
as keyFilter only. And in this line it refers to PREFERENCES_KEY_FILTER
directly. I feel that either it should not refer to PREFERENCES_KEY_FILTER or not have a keyFilter.
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.
Yes, you're right! Thanks for the pointing. keyFilter
argument actually has the same value as PREFERENCES_KEY_FILTER
has. Will replace constant value with argument value.
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.
Also will update name of the function, getPreferenceValue
is more preferred name for it.
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
E2E tests of Eclipse Che Multiuser on OCP has failed:
|
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.
LGTM
import static java.util.Collections.singletonMap; | ||
import static java.util.Optional.empty; | ||
import static java.util.Optional.of; | ||
import static java.util.Optional.ofNullable; |
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.
I'm not a fan of static imports of methods such as these, since names like of
are not descriptive at all. Up to you though, I know we do it all over the codebase currently.
Signed-off-by: Vlad Zhukovskyi <[email protected]>
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
E2E tests of Eclipse Che Multiuser on OCP has failed:
|
Selenium tests execution on Eclipse Che Multiuser on OCP (https://ci.codenvycorp.com/job/che-pullrequests-test-ocp/2174//Selenium_20tests_20report/) doesn't show any regression against this Pull request. |
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.
@vzhukovskii I was testing these changes on OpenShift, and it looks like the provisioning isn't included in OpenShiftEnvironmentProvisioner
.
What does this PR do?
This changes proposal adds ability to provision git configuration into each container at container startup. Configuration consists of user name and user email needed for git to sign user commits.
Linked PR on the Theia side, which provide preference editor to configure the values operated in this PR: eclipse-che/che-theia#424
Demo for this PR: https://www.youtube.com/watch?v=Q_XsUWR_mJY&feature=youtu.be
Signed-off-by: Vlad Zhukovskyi [email protected]
What issues does this PR fix or reference?
#13874
Release Notes
Provision git configuration into each container
Docs PR