mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-24 22:53:42 +00:00
33aa5d2d74
svn path=/nixos/trunk/; revision=9384
29 lines
592 B
Nix
29 lines
592 B
Nix
{config, pkgs}:
|
|
let
|
|
getCfg = option: config.get ["services" "gw6c" option];
|
|
procps = pkgs.procps;
|
|
gw6cService = import ../services/gw6c {
|
|
inherit (pkgs) stdenv gw6c coreutils
|
|
procps upstart iputils gnused
|
|
gnugrep;
|
|
username = getCfg "username";
|
|
password = getCfg "password";
|
|
server = getCfg "server";
|
|
keepAlive = getCfg "keepAlive";
|
|
everPing = getCfg "everPing";
|
|
};
|
|
in
|
|
{
|
|
name = "gw6c";
|
|
users = [];
|
|
groups = [];
|
|
job = "
|
|
description \"Gateway6 client\"
|
|
|
|
start on network-interfaces/started
|
|
stop on network-interfaces/stop
|
|
|
|
respawn ${gw6cService}/bin/control start
|
|
";
|
|
}
|