We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cb58d64 commit d5e0d68Copy full SHA for d5e0d68
pkg/k8sutil/haProxyHelper.go
@@ -268,14 +268,15 @@ backend {{ .BackendName }}
268
PortNumber: backends[0].Port,
269
Path: backends[0].Path,
270
}
271
+ if backends[0].IsPathBased {
272
+ backendTemplate += `
273
+ http-request replace-path {{.Path}}(/)?(.*) /\2`
274
+ }
275
result += parseTemplateToString(backendTemplate, data)
276
for _, backend := range backends {
277
name := backend.GroupName
278
groupReplicas := backend.Replicas
- if backend.IsPathBased {
- backendTemplate += `
- http-request replace-path {{.Path}}(/)?(.*) /\2`
- }
279
+
280
for i := 0; i < groupReplicas; i++ {
281
data := &HAProxyTemplate{
282
PortNumber: backend.TargetPort,
0 commit comments