Skip to content

Commit

Permalink
Fix to use regular expression
Browse files Browse the repository at this point in the history
  • Loading branch information
igsong committed Dec 12, 2019
1 parent 0d9c34a commit 94bf9ab
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/reconciler/route/resources/ingress.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ package resources

import (
"context"
"fmt"
"sort"

corev1 "k8s.io/api/core/v1"
Expand Down Expand Up @@ -144,7 +145,7 @@ func MakeIngressSpec(
if idx != defaultTargetRuleIndex {
tagBasedPath := rules[idx].HTTP.Paths[0].DeepCopy()
tagBasedPath.AppendHeaders = nil
tagBasedPath.Headers = map[string]string{RevisionHeaderTag: names[idx]}
tagBasedPath.Headers = map[string]string{RevisionHeaderTag: fmt.Sprintf("^%s$", names[idx])}
tagBasedPaths = append(tagBasedPaths, *tagBasedPath)
}
}
Expand Down

0 comments on commit 94bf9ab

Please sign in to comment.