Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 561fde4

Browse files
authored
[server] Fix custom CA (#20770)
Configure NODE_EXTRA_CA_CERTS env var to point to the CA certificate bundle file
1 parent 828784c commit 561fde4

File tree

3 files changed

+19
-5
lines changed

3 files changed

+19
-5
lines changed

‎install/installer/pkg/common/certificate.go‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ import (
88
corev1 "k8s.io/api/core/v1"
99
)
1010

11+
const CUSTOM_CA_MOUNT_PATH = "/etc/ssl/certs/ca-certificates.crt"
12+
1113
func CAVolume() corev1.Volume {
1214
return corev1.Volume{
1315
Name: "ca-certificates",
@@ -22,7 +24,7 @@ func CAVolume() corev1.Volume {
2224
func CAVolumeMount() corev1.VolumeMount {
2325
return corev1.VolumeMount{
2426
Name: "ca-certificates",
25-
MountPath: "/etc/ssl/certs/ca-certificates.crt",
27+
MountPath: CUSTOM_CA_MOUNT_PATH,
2628
SubPath: "ca-certificates.crt",
2729
ReadOnly: true,
2830
}

‎install/installer/pkg/components/server/deployment.go‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,11 @@ func deployment(ctx *common.RenderContext) ([]runtime.Object, error) {
102102
Name: "WSMAN_CFG_MANAGERS",
103103
Value: wsmanCfgManager,
104104
},
105+
// Required for node.js to pick up custom CAs
106+
{
107+
Name: "NODE_EXTRA_CA_CERTS",
108+
Value: common.CUSTOM_CA_MOUNT_PATH,
109+
},
105110
},
106111
)
107112

‎install/installer/pkg/components/ws-manager-bridge/deployment.go‎

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,10 +87,17 @@ func deployment(ctx *common.RenderContext) ([]runtime.Object, error) {
8787
common.AnalyticsEnv(&ctx.Config),
8888
common.DatabaseEnv(&ctx.Config),
8989
common.ConfigcatEnv(ctx),
90-
[]corev1.EnvVar{{
91-
Name: "WSMAN_BRIDGE_CONFIGPATH",
92-
Value: "/config/ws-manager-bridge.json",
93-
}},
90+
[]corev1.EnvVar{
91+
{
92+
Name: "WSMAN_BRIDGE_CONFIGPATH",
93+
Value: "/config/ws-manager-bridge.json",
94+
},
95+
// Required for node.js to pick up custom CAs
96+
{
97+
Name: "NODE_EXTRA_CA_CERTS",
98+
Value: common.CUSTOM_CA_MOUNT_PATH,
99+
},
100+
},
94101
))
95102

96103
_ = ctx.WithExperimental(func(cfg *experimental.Config) error {

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /