File tree Expand file tree Collapse file tree 3 files changed +28
-5
lines changed
src/components/Clusters/views/ClusterOverview
tests/integration/fixtures Expand file tree Collapse file tree 3 files changed +28
-5
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,7 @@ kubectl apply -f tests/integration/fixtures/community-modules
4747
4848echo " Apply Kyma provision fixture"
4949kubectl apply -f tests/integration/fixtures/kyma-info-cm.yaml
50+ kubectl apply -f tests/integration/fixtures/shoot-info-cm.yaml
5051
5152echo " Apply gardener resources"
5253echo " Certificates"
Original file line number Diff line number Diff line change 11import { useGet } from 'shared/hooks/BackendAPI/useGet' ;
22
33export function useGetEnvironmentParameters ( ) {
4- const { data : environmentParameters , loading : environmentParametersLoading } =
5- useGet ( '/api/v1/namespaces/kyma-system/configmaps/kyma-info' ) ;
4+ const {
5+ data : environmentParametersFromShootInfoCM ,
6+ loading : environmentParametersFromShootInfoCMLoading ,
7+ } = useGet ( '/api/v1/namespaces/kube-system/configmaps/shoot-info' ) ;
68
7- const natGatewayIps =
8- environmentParameters ?. data [ 'cloud.natGatewayIps' ] . split ( ', ' ) ;
9+ const {
10+ data : environmentParametersFromKymaInfoCM ,
11+ loading : environmentParametersFromKymaInfoCMLoading ,
12+ } = useGet ( '/api/v1/namespaces/kyma-system/configmaps/kyma-info' ) ;
913
10- return { natGatewayIps, environmentParametersLoading } ;
14+ const natGatewayIps = ! ! environmentParametersFromShootInfoCM
15+ ? environmentParametersFromShootInfoCM ?. data [ 'egressCIDRs' ] ?. split ( ',' )
16+ : environmentParametersFromKymaInfoCM ?. data [ 'cloud.natGatewayIps' ] ?. split (
17+ ', ' ,
18+ ) ;
19+
20+ return {
21+ natGatewayIps,
22+ environmentParametersLoading :
23+ environmentParametersFromShootInfoCMLoading |
24+ environmentParametersFromKymaInfoCMLoading ,
25+ } ;
1126}
Original file line number Diff line number Diff line change 1+ kind : ConfigMap
2+ apiVersion : v1
3+ metadata :
4+ name : shoot-info
5+ namespace : kube-system
6+ data :
7+ egressCIDRs : 3.74.173.24/32,63.177.125.178/32,18.157.247.144/32
You can’t perform that action at this time.
0 commit comments