summaryrefslogtreecommitdiffstats
path: root/krebs/default.nix
diff options
context:
space:
mode:
authorlassulus <lass@aidsballs.de>2016-01-10 12:34:09 +0100
committerlassulus <lass@aidsballs.de>2016-01-10 12:34:09 +0100
commit9737eeed58e2dfc8e4efcfe1e02dc2f315116e90 (patch)
treee100bcd397d114f470a7ea639a9e6689dee38ebb /krebs/default.nix
parent3f4cec9196253a72833d7b8e8328227ce665eefe (diff)
parent49b6fd9c87678893ed47794b116660700994b1bc (diff)
Merge remote-tracking branch 'gum/master'
Diffstat (limited to 'krebs/default.nix')
-rw-r--r--krebs/default.nix9
1 files changed, 4 insertions, 5 deletions
diff --git a/krebs/default.nix b/krebs/default.nix
index 81ddd3ea6..15d0e8e2e 100644
--- a/krebs/default.nix
+++ b/krebs/default.nix
@@ -50,7 +50,6 @@ let out = {
# Prepare target source via bind-mounting
- (${populate (args // { infesting = true;}) })
(${nixos-install args})
@@ -103,6 +102,7 @@ let out = {
#! /bin/sh
# ${current-date} ${current-user-name}@${current-host-name}
# krebs.nixos-install
+ (${populate (args // { root = "/mnt"; })})
${rootssh target ''
export PATH; PATH=/root/.nix-profile/bin:$PATH
@@ -209,7 +209,7 @@ let out = {
populate =
{ system ? current-host-name
, target ? system
- , infesting ? false
+ , root ? ""
}@args:
let out = ''
#! /bin/sh
@@ -223,7 +223,6 @@ let out = {
'';
- target_prefix=lib.optionalString infesting "/mnt";
config = get-config system;
current-host = config.krebs.hosts.${current-host-name};
@@ -232,7 +231,7 @@ let out = {
methods.dir = config:
let
can-push = config.host.name == current-host.name;
- target-path = target_prefix + config.target-path;
+ target-path = root + config.target-path;
push-method = ''
rsync \
--exclude .git \
@@ -252,7 +251,7 @@ let out = {
throw "No way to push ${dir} from ${current-host.name} to ${target}";
methods.git = config:
- let target-path = target_prefix + config.target-path;
+ let target-path = root + config.target-path;
in rootssh target ''
mkdir -p ${target-path}
cd ${target-path}