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

We should use services hostname instead of ingresses for inter-components communications #17644

Closed
l0rd opened this issue Aug 17, 2020 · 4 comments
Assignees
Labels
area/che-operator Issues and PRs related to Eclipse Che Kubernetes Operator area/che-server kind/enhancement A feature request - must adhere to the feature request template. severity/P1 Has a major impact to usage or development of the system.
Milestone

Comments

@l0rd
Copy link
Contributor

l0rd commented Aug 17, 2020

Is your enhancement related to a problem? Please describe.

When wsmaster try to reach Keycloak it uses its external ingress/route hostname instead of using the internal service hostname. That makes sense only if Keycloak is external (the exception).

This is a problem because HTTP requests may need to follow a complicated and venturesome path going through proxies, firewalls etc...

This is NOT a wsmaster <--> keycloack specific problem. The plugin broker has the same issue when communicating with the registries and the wsmaster. And other Che components may have the same problem.

Describe the solution you'd like

All communications between Che services, by default, should use the cluster internal service hostname.

@l0rd l0rd added the kind/enhancement A feature request - must adhere to the feature request template. label Aug 17, 2020
@che-bot che-bot added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Aug 17, 2020
@sleshchenko
Copy link
Member

All communications between Che services, by default, should use the cluster internal service hostname.

I think it worths to declare that different communication should be configurable like Che and Keycloak are run in the same namespace and there is no reason to use external networking except external keycloak is used ( as is described in the issue ).
But Plugin Broker - Che Server communication should be configured according to cluster network policies, since those components are run in a different namespace and usually ( I think ) Che Server is not available for Plugin Broker via service hostname (internal network).

@tomgeorge tomgeorge added severity/P2 Has a minor but important impact to the usage or development of the system. area/che-operator Issues and PRs related to Eclipse Che Kubernetes Operator area/che-server severity/P1 Has a major impact to usage or development of the system. and removed status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. severity/P2 Has a minor but important impact to the usage or development of the system. labels Aug 17, 2020
@l0rd
Copy link
Contributor Author

l0rd commented Aug 17, 2020

Che Server communication should be configured according to cluster network policies, since those components are run in a different namespace and usually ( I think ) Che Server is not available for Plugin Broker via service hostname (internal network).

@sleshchenko you are probably referring to the OpenShift Online cluster (che.osio) network policy that blocks communications across namespaces. That's a cluster with a peculiar configuration. By default communications across namespaces are enabled on both Kubernetes and OpenShift.

@tolusha tolusha mentioned this issue Aug 20, 2020
58 tasks
@tolusha tolusha added this to the 7.19 milestone Aug 26, 2020
@tolusha tolusha mentioned this issue Sep 8, 2020
48 tasks
@tolusha tolusha modified the milestones: 7.19, 7.20 Sep 10, 2020
@AndrienkoAleksandr AndrienkoAleksandr self-assigned this Sep 14, 2020
@AndrienkoAleksandr
Copy link
Contributor

Hello. @l0rd , @sleshchenko we are going to introduce cheCluster settings to enable internal network. Let's call it useInternalNetwork and it will be disabled by default. I think it will be safe way to start playing with this stuff.

@tolusha tolusha modified the milestones: 7.22, 7.23 Nov 11, 2020
@tolusha tolusha mentioned this issue Nov 16, 2020
58 tasks
@ibuziuk
Copy link
Member

ibuziuk commented Nov 23, 2020

Not sure if this is relevant but in order to achive the network isolation on 3.11 the multitenant sdn
plugin is used https://docs.openshift.com/container-platform/3.11/architecture/networking/sdn.html which enables multi-tenant mode.

for 4.x clusters network policy is used to achieve multitenancy - https://docs.openshift.com/container-platform/4.1/networking/configuring-networkpolicy.html#nw-networkpolicy-multitenant-isolation_configuring-networkpolicy-plugin

By default, all Pods in a project are accessible from other Pods and network endpoints. To isolate one or more Pods in a project, you can create NetworkPolicy objects in that project to indicate the allowed incoming connections. Project administrators can create and delete NetworkPolicy objects within their own project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/che-operator Issues and PRs related to Eclipse Che Kubernetes Operator area/che-server kind/enhancement A feature request - must adhere to the feature request template. severity/P1 Has a major impact to usage or development of the system.
Projects
None yet
Development

No branches or pull requests

7 participants