From 4bc36b3484148f54ff994fa0f11a5286827595b2 Mon Sep 17 00:00:00 2001 From: maritu Date: Thu, 14 Mar 2024 03:45:36 +0300 Subject: [PATCH] docs: Add MAC VTAP example Signed-off-by: maritu --- examples/macvtap.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 examples/macvtap.yml diff --git a/examples/macvtap.yml b/examples/macvtap.yml new file mode 100644 index 0000000..888f8a2 --- /dev/null +++ b/examples/macvtap.yml @@ -0,0 +1,29 @@ +# SPDX-License-Identifier: BSD-3-Clause +--- +- name: Manage network MAC VTAP + hosts: network-test + vars: + network_connections: + - name: eth0 + type: ethernet + state: up + interface_name: eth0 + ip: + address: + - 192.168.0.1/24 + + # Create a virtual ethernet card bound to eth0 + - name: veth0 + type: macvlan + state: up + parent: eth0 + macvlan: + mode: bridge + promiscuous: true + tap: true + ip: + address: + - 192.168.1.1/24 + + roles: + - linux-system-roles.network