Compare commits
No commits in common. "59632cb3f7519ceb4531c031f257ed1bdd44152b" and "e639bcc8f01ced00ca5ecc118567e3f0f7c43552" have entirely different histories.
59632cb3f7
...
e639bcc8f0
2 changed files with 4 additions and 19 deletions
|
@ -26,8 +26,6 @@
|
|||
delete_subvolume_recursively "$i"
|
||||
done
|
||||
|
||||
echo 1 | tee /btrfs_tmp/root/sys/class/leds/asus\:\:kbd_backlight/brightness
|
||||
|
||||
btrfs subvolume create /btrfs_tmp/root
|
||||
umount /btrfs_tmp
|
||||
rm -r /btrfs_tmp
|
||||
|
@ -53,6 +51,7 @@
|
|||
"/etc/ssh/ssh_host_rsa_key.pub"
|
||||
"/etc/ssh/ssh_host_ed25519_key"
|
||||
"/etc/ssh/ssh_host_ed25519_key.pub"
|
||||
"/sys/class/leds/asus\:\:kbd_backlight/brightness"
|
||||
];
|
||||
};
|
||||
"/persistent/docker" = lib.mkIf config.virtualisation.docker.enable {
|
||||
|
|
|
@ -2,11 +2,6 @@
|
|||
|
||||
let
|
||||
cfg = config.local.services.vpn.wireguard;
|
||||
|
||||
addrsViaDefaultInterface = [
|
||||
# cache.nixos.org
|
||||
"151.101.86.217/32"
|
||||
];
|
||||
in
|
||||
{
|
||||
options.local.services.vpn.wireguard = with lib; {
|
||||
|
@ -51,18 +46,9 @@ in
|
|||
postUp = ''
|
||||
addr=`${pkgs.iproute}/bin/ip route | ${pkgs.gawk}/bin/awk '/default/ {print $3; exit}'`
|
||||
interface=`${pkgs.iproute}/bin/ip route | ${pkgs.gawk}/bin/awk '/default/ {print $5; exit}'`
|
||||
'' + lib.concatLines (map
|
||||
(addr: "${pkgs.iproute}/bin/ip route add ${addr} via $addr dev $interface")
|
||||
addrsViaDefaultInterface
|
||||
);
|
||||
|
||||
preDown = ''
|
||||
addr=`${pkgs.iproute}/bin/ip route | ${pkgs.gawk}/bin/awk '/default/ {print $3; exit}'`
|
||||
interface=`${pkgs.iproute}/bin/ip route | ${pkgs.gawk}/bin/awk '/default/ {print $5; exit}'`
|
||||
'' + lib.concatLines (map
|
||||
(addr: "${pkgs.iproute}/bin/ip route del ${addr} via $addr dev $interface")
|
||||
addrsViaDefaultInterface
|
||||
);
|
||||
# don't use wg with cache.nixos.org
|
||||
${pkgs.iproute}/bin/ip route add 151.101.86.217/32 via $addr dev $interface
|
||||
'';
|
||||
|
||||
peers = [
|
||||
# For a client configuration, one peer entry for the server will suffice.
|
||||
|
|
Loading…
Reference in a new issue