diff options
author | Netix (Espinet François) <dev.espinetfrancois@gmail.com> | 2018-12-29 11:16:51 +0100 |
---|---|---|
committer | Netix (Espinet François) <dev.espinetfrancois@gmail.com> | 2019-12-15 21:16:26 +0100 |
commit | cd3597b4864935a8dc978b711a4847a6132b8a2c (patch) | |
tree | 2929b85e5b29fe4e2c4095b75a4b3ff22257b670 /nixos/modules/virtualisation/openvswitch.nix | |
parent | aa4a1b01d5180f9ceee99b16dd007672aa3f2dee (diff) |
openvswitch: better integration with systemd
Systemd dependencies for scripted mode were refactored according to analysis in #34586. networking.vswitches can now be used with systemd-networkd, although they are not supported by the daemon, a nixos receipe creates the switch and attached required interfaces (just like the scripted version). Vlans and internal interfaces are implemented following the template format i.e. each interface is described using an attributeSet (vlan and type at the moment). If vlan is present, then interface is added to the vswitch with given tag (access mode). Type internal enabled vswitch to create interfaces (see openvswitch docs). Added configuration for configuring supported openFlow version on the vswitch This commit is a split from the original PR #35127.
Diffstat (limited to 'nixos/modules/virtualisation/openvswitch.nix')
-rw-r--r-- | nixos/modules/virtualisation/openvswitch.nix | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/nixos/modules/virtualisation/openvswitch.nix b/nixos/modules/virtualisation/openvswitch.nix index 6b8ad83661fe7..c6a3ceddc3e03 100644 --- a/nixos/modules/virtualisation/openvswitch.nix +++ b/nixos/modules/virtualisation/openvswitch.nix @@ -124,7 +124,7 @@ in { ''; }; - systemd.services.vswitchd = { + systemd.services.ovs-vswitchd = { description = "Open_vSwitch Daemon"; wantedBy = [ "multi-user.target" ]; bindsTo = [ "ovsdb.service" ]; @@ -139,6 +139,8 @@ in { PIDFile = "/run/openvswitch/ovs-vswitchd.pid"; # Use service type 'forking' to correctly determine when vswitchd is ready. Type = "forking"; + Restart = "always"; + RestartSec = 3; }; }; @@ -182,4 +184,7 @@ in { ''; }; })])); + + meta.maintainers = with maintainers; [ netixx ]; + } |