summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2016-02-15 17:43:30 +0100
committermakefu <github@syntax-fehler.de>2016-02-15 17:43:30 +0100
commita94a4c42065fb2fd489a03fd7b0db60ebabb8ebf (patch)
tree0d8f381eb4210a6b1abe80f27692401a0ce18e4f
parent3ceff0ec29a36119ea83f02c8943752d91b250e9 (diff)
s 1 wolf: use config.krebs.lib
-rw-r--r--krebs/3modules/buildbot/master.nix4
-rw-r--r--krebs/3modules/buildbot/slave.nix6
-rw-r--r--krebs/3modules/repo-sync.nix5
-rw-r--r--shared/2configs/shack-drivedroid.nix4
4 files changed, 9 insertions, 10 deletions
diff --git a/krebs/3modules/buildbot/master.nix b/krebs/3modules/buildbot/master.nix
index 825cb3413..080a1f33d 100644
--- a/krebs/3modules/buildbot/master.nix
+++ b/krebs/3modules/buildbot/master.nix
@@ -338,8 +338,8 @@ let
SSL_CERT_FILE = "${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt";
};
serviceConfig = let
- workdir="${lib.shell.escape cfg.workDir}";
- secretsdir="${lib.shell.escape (toString <secrets>)}";
+ workdir="${shell.escape cfg.workDir}";
+ secretsdir="${shell.escape (toString <secrets>)}";
in {
PermissionsStartOnly = true;
Type = "forking";
diff --git a/krebs/3modules/buildbot/slave.nix b/krebs/3modules/buildbot/slave.nix
index 7705ac31c..0375e8023 100644
--- a/krebs/3modules/buildbot/slave.nix
+++ b/krebs/3modules/buildbot/slave.nix
@@ -149,9 +149,9 @@ let
} // cfg.extraEnviron;
serviceConfig = let
- workdir = "${lib.shell.escape cfg.workDir}";
- contact = "${lib.shell.escape cfg.contact}";
- description = "${lib.shell.escape cfg.description}";
+ workdir = "${shell.escape cfg.workDir}";
+ contact = "${shell.escape cfg.contact}";
+ description = "${shell.escape cfg.description}";
buildbot = pkgs.buildbot-slave;
# TODO:make this
in {
diff --git a/krebs/3modules/repo-sync.nix b/krebs/3modules/repo-sync.nix
index c92d458dd..7a7c80a75 100644
--- a/krebs/3modules/repo-sync.nix
+++ b/krebs/3modules/repo-sync.nix
@@ -1,7 +1,6 @@
{ config, lib, pkgs, ... }:
with lib;
-
let
cfg = config.krebs.repo-sync;
@@ -71,7 +70,7 @@ let
imp = {
users.users.repo-sync = {
name = "repo-sync";
- uid = genid "repo-sync";
+ uid = config.krebs.lib.genid "repo-sync";
description = "repo-sync user";
home = cfg.stateDir;
createHome = true;
@@ -98,7 +97,7 @@ let
PermissionsStartOnly = true;
ExecStartPre = pkgs.writeScript "prepare-repo-sync-user" ''
#! /bin/sh
- cp -v ${lib.shell.escape cfg.privateKeyFile} ${cfg.stateDir}/ssh.priv
+ cp -v ${config.krebs.lib.shell.escape cfg.privateKeyFile} ${cfg.stateDir}/ssh.priv
chown repo-sync ${cfg.stateDir}/ssh.priv
'';
ExecStart = "${pkgs.repo-sync}/bin/repo-sync ${repo-sync-config}";
diff --git a/shared/2configs/shack-drivedroid.nix b/shared/2configs/shack-drivedroid.nix
index 08a6b0697..2e9d2c002 100644
--- a/shared/2configs/shack-drivedroid.nix
+++ b/shared/2configs/shack-drivedroid.nix
@@ -1,7 +1,8 @@
{ pkgs, lib, config, ... }:
+
let
repodir = "/var/srv/drivedroid";
- srepodir = lib.shell.escape repodir;
+ srepodir = config.krebs.lib.shell.escape repodir;
in
{
environment.systemPackages = [ pkgs.drivedroid-gen-repo ];
@@ -40,5 +41,4 @@ in
};
};
};
-
}