summary refs log tree commit diff
path: root/nixos/modules/services/networking/wicd.nix
blob: 9e5a437b48569a28a6462d4afa0d052d0d88abbd (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
{ config, lib, pkgs, ... }:

with lib;

{

  ###### interface

  options = {

    networking.wicd.enable = mkOption {
      default = false;
      description = ''
        Whether to start <command>wicd</command>. Wired and
        wireless network configurations can then be managed by
        wicd-client.
      '';
    };
  };


  ###### implementation

  config = mkIf config.networking.wicd.enable {

    environment.systemPackages = [pkgs.wicd];

    systemd.services.wicd = {
      after = [ "network-interfaces.target" ];
      wantedBy = [ "multi-user.target" ];
      script = "${pkgs.wicd}/sbin/wicd -f";
    };

    services.dbus.enable = true;
    services.dbus.packages = [pkgs.wicd];
  };
}