nixos-module/container/upstream/pppoe: fix user option

This commit is contained in:
Astro 2021-11-13 03:23:45 +01:00
parent e2580e78fd
commit 624f2e38f6
1 changed files with 3 additions and 3 deletions

View File

@ -16,13 +16,13 @@ in lib.mkIf (pppoeInterfaces != {}) {
environment.etc."ppp/pap-secrets".text = lib.concatMapStrings (ifName:
let
inherit (pppoeInterfaces.${ifName}) user password;
inherit (pppoeInterfaces.${ifName}.upstream) user password;
in ''
"${user}" * "${password}"
'') (builtins.attrNames pppoeInterfaces);
services.pppd = {
enable = true;
peers = builtins.mapAttrs (ifName: { upstream, user, ... }: {
peers = builtins.mapAttrs (ifName: { upstream, ... }: {
enable = true;
autostart = true;
config = ''
@ -30,7 +30,7 @@ in lib.mkIf (pppoeInterfaces != {}) {
nic-${upstream.link}
ifname ${ifName}
# Login settings. (PAP)
name "${user}"
name "${upstream.user}"
noauth
hide-password
# Connection settings.