decoysnail: use superior systemd-resolved

This commit is contained in:
Gabriel Ebner 2019-02-19 13:12:08 +01:00
parent ee25b7e75e
commit e76bccb537
1 changed files with 7 additions and 4 deletions

View File

@ -62,10 +62,8 @@
privateKeyFile = "/etc/wgkeys/decoysnail";
allowedIPsAsRoutes = true;
postSetup = ''
printf "nameserver 10.57.0.1" | ${pkgs.openresolv}/bin/resolvconf -a wg0 -m 0
'';
postShutdown = ''
${pkgs.openresolv}/bin/resolvconf -d wg0
${pkgs.systemd}/bin/resolvectl domain wg0 '~htdf.gebner.org' '~mtlaa.gebner.org'
${pkgs.systemd}/bin/resolvectl dns wg0 10.57.0.1
'';
peers = [{
publicKey = "ByLlJbevlTBooAo2RIZGGJvBHKqA9qiOpHBvR5yuJX4=";
@ -75,4 +73,9 @@
}];
};
services.resolved = {
domains = [];
enable = true;
};
}