Skip to content

Commit 82312f1

Browse files
authored
Merge pull request #268 from crossplane-contrib/pre-release
chore(release): merge pre-release into main for v4.4.0
2 parents ff61724 + 8b241bf commit 82312f1

22 files changed

Lines changed: 671 additions & 377 deletions

.github/workflows/helm-release.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,9 @@ jobs:
101101

102102
- name: Install Helm unittest plugin
103103
run: |
104-
helm plugin install https://github.com/quintush/helm-unittest.git || true
104+
helm plugin install https://github.com/helm-unittest/helm-unittest --version v0.6.0
105+
helm plugin list
106+
test -x "$(helm env HELM_PLUGINS)/helm-unittest/untt"
105107
106108
- name: Run Helm Tests
107109
run: |

CHANGELOG.md

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
1-
# [3.9.0](https://github.com/crossplane-contrib/crossview/compare/v3.8.0...v3.9.0) (2026-04-13)
1+
# [4.4.0](https://github.com/crossplane-contrib/crossview/compare/v3.9.0...v4.4.0) (2026-05-19)
22

33

44
### Bug Fixes
55

6-
* fix Crossplane v2 composite resource managed resource relation visualization ([f8cc7b1](https://github.com/crossplane-contrib/crossview/commit/f8cc7b15a861a247952f903773059aef303836d1))
7-
* **ci:** enforce semantic versioning validation in release workflows ([ec011e5](https://github.com/crossplane-contrib/crossview/commit/ec011e52bb877a5e138daa0be6d52f0702890048))
8-
* **version-check:** compare prerelease versions correctly and pick highest release ([1855c65](https://github.com/crossplane-contrib/crossview/commit/1855c65bccadc840fd53e36bb59625f5485f60e1))
6+
* **ci:** make helm-unittest plugin install deterministic ([01bad86](https://github.com/crossplane-contrib/crossview/commit/01bad86825b05851e4c3af8dec0a64651f11da7f))
7+
* **cache:** fix caching and managed resource definition/policy readability ([3a7f9a6](https://github.com/crossplane-contrib/crossview/commit/3a7f9a69d7a3033b5425d20f60dba25cc7b105f2))
8+
* **ui:** pass namespace when navigating from namespaced XR to managed resources ([74892d6](https://github.com/crossplane-contrib/crossview/commit/74892d67232a9cf9f59ca070513d13279a185d90))
99

1010

1111
### Features
1212

13-
* make releases manual with controlled trigger ([3f4ff29](https://github.com/crossplane-contrib/crossview/commit/3f4ff298b88fb5a529e8ead314eceb5e938e7dfa))
14-
* **ui:** add version display and update indicator to sidebar footer ([61408a8](https://github.com/crossplane-contrib/crossview/commit/61408a82e6c3fccc55c8c220f6825106db6f6233))
15-
* **ui:** support deep links for composite kind details ([4759e5a](https://github.com/crossplane-contrib/crossview/commit/4759e5a77a81e32474824109f784b49b474685a7))
13+
* **resource-relations:** modularize graph UI, refine health/navigation behavior, and improve relation rendering ([8eda498](https://github.com/crossplane-contrib/crossview/commit/8eda498514436ab651d96a7005c5fc92b1d86c46))
1614

1715

1816
### Other
1917

20-
* update GitHub issue templates ([ef268bd](https://github.com/crossplane-contrib/crossview/commit/ef268bdbd54df3037d38a0a79a0f5989696cd98e))
18+
* clean up unused code and improve error handling in optimized context switching flow ([339944b](https://github.com/crossplane-contrib/crossview/commit/339944b585e1796268639035db7a3c9525ab3156))

crossview-go-server/services/kubernetes_context.go

Lines changed: 37 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,36 @@ func (k *KubernetesService) getKubeConfigPath() string {
3030
return filepath.Join(homeDir, ".kube", "config")
3131
}
3232

33+
func (k *KubernetesService) normalizeKubeConfigPaths() error {
34+
kubeConfigPath := k.getKubeConfigPath()
35+
kubeConfigDir := filepath.Dir(kubeConfigPath)
36+
37+
for clusterName, cluster := range k.kubeConfig.Clusters {
38+
if cluster != nil && cluster.CertificateAuthority != "" {
39+
certPath := cluster.CertificateAuthority
40+
if !filepath.IsAbs(certPath) {
41+
absPath := filepath.Join(kubeConfigDir, certPath)
42+
cluster.CertificateAuthority = absPath
43+
k.kubeConfig.Clusters[clusterName] = cluster
44+
}
45+
}
46+
}
47+
48+
for authName, authInfo := range k.kubeConfig.AuthInfos {
49+
if authInfo != nil {
50+
if authInfo.ClientCertificate != "" && !filepath.IsAbs(authInfo.ClientCertificate) {
51+
authInfo.ClientCertificate = filepath.Join(kubeConfigDir, authInfo.ClientCertificate)
52+
}
53+
if authInfo.ClientKey != "" && !filepath.IsAbs(authInfo.ClientKey) {
54+
authInfo.ClientKey = filepath.Join(kubeConfigDir, authInfo.ClientKey)
55+
}
56+
k.kubeConfig.AuthInfos[authName] = authInfo
57+
}
58+
}
59+
60+
return nil
61+
}
62+
3363
func (k *KubernetesService) loadKubeConfig() error {
3464
kubeConfigPath := k.getKubeConfigPath()
3565
if kubeConfigPath == "" {
@@ -46,12 +76,15 @@ func (k *KubernetesService) loadKubeConfig() error {
4676
}
4777

4878
k.kubeConfig = config
79+
if err := k.normalizeKubeConfigPaths(); err != nil {
80+
return err
81+
}
4982
return nil
5083
}
5184

5285
func (k *KubernetesService) isInCluster() bool {
5386
serviceAccountPath := "/var/run/secrets/kubernetes.io/serviceaccount"
54-
return fileExists(serviceAccountPath) &&
87+
return fileExists(serviceAccountPath) &&
5588
fileExists(filepath.Join(serviceAccountPath, "token")) &&
5689
fileExists(filepath.Join(serviceAccountPath, "ca.crt"))
5790
}
@@ -120,7 +153,7 @@ func (k *KubernetesService) SetContext(ctxName string) error {
120153
k.clientset = clientset
121154
k.dynamicClient = nil
122155
delete(k.failedContexts, targetContext)
123-
156+
124157
// Clear managed resources cache when context changes
125158
k.managedResourcesCache = make(map[string]map[string]interface{})
126159
k.managedResourcesCacheTime = make(map[string]time.Time)
@@ -135,7 +168,7 @@ func (k *KubernetesService) SetContext(ctxName string) error {
135168

136169
func (k *KubernetesService) IsConnected(ctxName string) (bool, error) {
137170
originalContext := k.GetCurrentContext()
138-
171+
139172
if err := k.SetContext(ctxName); err != nil {
140173
return false, err
141174
}
@@ -155,7 +188,7 @@ func (k *KubernetesService) IsConnected(ctxName string) (bool, error) {
155188
if originalContext != "" && originalContext != ctxName {
156189
k.SetContext(originalContext)
157190
}
158-
191+
159192
if err != nil {
160193
return false, err
161194
}
@@ -281,4 +314,3 @@ func (k *KubernetesService) RemoveContext(ctxName string) error {
281314

282315
return nil
283316
}
284-

0 commit comments

Comments
 (0)