Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add TrafficControl API #3644

Merged
merged 1 commit into from
Apr 27, 2022
Merged

Add TrafficControl API #3644

merged 1 commit into from
Apr 27, 2022

Commits on Apr 26, 2022

  1. Add TrafficControl API

    TrafficControl is a feature which allows mirroring or redirecting the
    traffic Pods send or receive. It enables users to monitor and analyze
    Pod traffic, and to enforce custom network protections for Pods with
    fine-grained control over network traffic.
    
    This patch adds types and CRD for TrafficControl API.
    
    Examples:
    
    1. Mirror Pods (web=app) ingress traffic to a VXLAN tunnel
    ```
    apiVersion: crd.antrea.io/v1alpha2
    kind: TrafficControl
    metadata:
      name: mirror-web-app
    spec:
      appliedTo:
        podSelector:
          matchLabels:
            app: web
      direction: Ingress
      action: Mirror
      targetPort:
        vxlan:
          remoteIP: 1.1.1.1
    ```
    
    2. Redirect Pods (web=app) traffic in both direction to OVS internal
    port firewall0 and expect the traffic to re-enter OVS via another OVS
    internal port firewall1 if they are not dropped.
    ```
    apiVersion: crd.antrea.io/v1alpha2
    kind: TrafficControl
    metadata:
      name: redirect
    spec:
      appliedTo:
        podSelector:
          matchLabels:
            role: web
      direction: Ingress
      action: Redirect
      targetPort:
        ovsInternal:
          name: firewall0
      returnPort:
        ovsInternal:
          name: firewall1
    ```
    
    For antrea-io#3324
    
    Signed-off-by: Quan Tian <[email protected]>
    tnqn committed Apr 26, 2022
    Configuration menu
    Copy the full SHA
    442ae83 View commit details
    Browse the repository at this point in the history