From 5d45ddbfaa44d29eb6077153248806d73ceabde9 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Fri, 10 Mar 2023 22:36:47 +0100 Subject: surtr: bifrost dscp --- hosts/surtr/bifrost/default.nix | 14 +++++++++++++- hosts/surtr/borg.nix | 2 ++ 2 files changed, 15 insertions(+), 1 deletion(-) (limited to 'hosts/surtr') diff --git a/hosts/surtr/bifrost/default.nix b/hosts/surtr/bifrost/default.nix index bdedf5b6..ccf0c959 100644 --- a/hosts/surtr/bifrost/default.nix +++ b/hosts/surtr/bifrost/default.nix @@ -1,4 +1,4 @@ -{ config, lib, ... }: +{ config, lib, pkgs, ... }: with lib; @@ -56,5 +56,17 @@ in { format = "binary"; sopsFile = ./surtr.priv; }; + + systemd.services."bifrost-dscp" = { + wantedBy = ["sys-subsystem-net-devices-bifrost.device"]; + after = ["sys-subsystem-net-devices-bifrost.device"]; + bindsTo = ["sys-subsystem-net-devices-bifrost.device"]; + + serviceConfig = { + Type = "oneshot"; + ExecStart = "${pkgs.preserve-dscp}/bin/preserve-dscp bifrost ens3"; + ExecStop = "${pkgs.preserve-dscp}/bin/preserve-dscp bifrost ens3 --unload"; + }; + }; }; } diff --git a/hosts/surtr/borg.nix b/hosts/surtr/borg.nix index b9fe53d7..ad4e5694 100644 --- a/hosts/surtr/borg.nix +++ b/hosts/surtr/borg.nix @@ -29,6 +29,8 @@ with lib; BatchMode yes ServerAliveInterval 10 ServerAliveCountMax 30 + + IPQoS cs1 ''; }; -- cgit v1.2.3