(synthesizedComp *SynthesizedComponent)
| 93 | } |
| 94 | |
| 95 | func IsHostNetworkEnabled(synthesizedComp *SynthesizedComponent) bool { |
| 96 | if !hasHostNetworkCapability(synthesizedComp, nil) { |
| 97 | return false |
| 98 | } |
| 99 | // legacy definition, ignore the cluster annotations |
| 100 | if synthesizedComp.PodSpec.HostNetwork { |
| 101 | return true |
| 102 | } |
| 103 | return hasHostNetworkEnabled(synthesizedComp.Annotations, synthesizedComp.Name) |
| 104 | } |
| 105 | |
| 106 | func isHostNetworkEnabled(ctx context.Context, cli client.Reader, synthesizedComp *SynthesizedComponent, compName string) (bool, error) { |
| 107 | // fast path: refer to self |
no test coverage detected
searching dependent graphs…