populate dir: drop link-method fragments
This commit is contained in:
parent
2efaf0f219
commit
acb53c23dc
@ -203,11 +203,8 @@ let out = {
|
||||
current-host = config.krebs.hosts.${current-host-name};
|
||||
current-user = config.krebs.users.${current-user-name};
|
||||
|
||||
target-host = config.krebs.hosts.${system};
|
||||
|
||||
methods.dir = config:
|
||||
let
|
||||
can-link = config.host.name == target-host.name;
|
||||
can-push = config.host.name == current-host.name;
|
||||
push-method = ''
|
||||
rsync \
|
||||
@ -219,13 +216,12 @@ let out = {
|
||||
--delete-excluded \
|
||||
-vrLptgoD \
|
||||
${config.path}/ \
|
||||
root@${target}:${config.target-path}
|
||||
${target-url}
|
||||
'';
|
||||
current-url = "${current-user-name}@${current-host.name}";
|
||||
source-url = "file://${config.host.name}${config.path}";
|
||||
target-url = "root@${target}:${config.target-path}";
|
||||
in
|
||||
#if can-link then link-method else
|
||||
if can-push then push-method else
|
||||
throw
|
||||
# /!\ revise this message when using more than just push-method
|
||||
|
Loading…
Reference in New Issue
Block a user