Merge pull request #745 from Nerja/delegate

Fix for VirtualService delegation when analysis is enabled
This commit is contained in:
Stefan Prodan
2020-12-09 10:08:20 +02:00
committed by GitHub
2 changed files with 6 additions and 1 deletions
+6
View File
@@ -215,6 +215,12 @@ func (ir *IstioRouter) reconcileVirtualService(canary *flaggerv1.Canary) error {
return fmt.Errorf("VirtualService %s.%s get query error %v", apexName, canary.Namespace, err)
}
if canary.Spec.Service.Delegation {
// delegate VirtualService requires the hosts and gateway empty.
virtualService.Spec.Gateways = []string{}
virtualService.Spec.Hosts = []string{}
}
// update service but keep the original destination weights and mirror
if virtualService != nil {
if diff := cmp.Diff(
-1
View File
@@ -70,7 +70,6 @@ spec:
targetPort: 9898
portDiscovery: true
delegation: true
skipAnalysis: true
analysis:
interval: 15s
threshold: 15