amnezia-vpn: fix awg connection

sund3RRR da3a63b2 d07b3731

+21 -3
+21 -3
pkgs/by-name/am/amnezia-vpn/package.nix
··· 23 bash, 24 }: 25 let 26 amnezia-tun2socks = tun2socks.overrideAttrs ( 27 finalAttrs: prevAttrs: { 28 pname = "amnezia-tun2socks"; ··· 77 78 postPatch = '' 79 substituteInPlace client/platforms/linux/daemon/wireguardutilslinux.cpp \ 80 - --replace-fail 'm_tunnel.start(appPath.filePath("../../client/bin/wireguard-go"), wgArgs);' 'm_tunnel.start("${amneziawg-go}/bin/amneziawg-go", wgArgs);' 81 substituteInPlace client/utilities.cpp \ 82 --replace-fail 'return Utils::executable("../../client/bin/openvpn", true);' 'return Utils::executable("${openvpn}/bin/openvpn", false);' \ 83 --replace-fail 'return Utils::executable("../../client/bin/tun2socks", true);' 'return Utils::executable("${amnezia-tun2socks}/bin/amnezia-tun2socks", false);' \ ··· 146 ''; 147 148 passthru = { 149 - inherit amnezia-tun2socks amnezia-xray; 150 updateScript = nix-update-script { 151 extraArgs = [ 152 "--subpackage" 153 "amnezia-tun2socks" 154 "--subpackage" 155 "amnezia-xray" 156 ]; 157 }; 158 }; ··· 164 license = licenses.gpl3; 165 mainProgram = "AmneziaVPN"; 166 maintainers = with maintainers; [ sund3RRR ]; 167 - platforms = platforms.unix; 168 }; 169 })
··· 23 bash, 24 }: 25 let 26 + awg-vendored = amneziawg-go.overrideAttrs ( 27 + finalAttrs: prevAttrs: { 28 + name = "amneziawg-go"; 29 + version = "0.2.13"; 30 + 31 + src = fetchFromGitHub { 32 + owner = "amnezia-vpn"; 33 + repo = "amneziawg-go"; 34 + tag = "v${finalAttrs.version}"; 35 + hash = "sha256-vXSPUGBMP37kXJ4Zn5TDLAzG8N+yO/IIj9nSKrZ+sFA="; 36 + }; 37 + 38 + vendorHash = "sha256-9OtIb3UQXpAA0OzPhDIdb9lXZQHHiYCcmjHAU+vCtpk="; 39 + } 40 + ); 41 + 42 amnezia-tun2socks = tun2socks.overrideAttrs ( 43 finalAttrs: prevAttrs: { 44 pname = "amnezia-tun2socks"; ··· 93 94 postPatch = '' 95 substituteInPlace client/platforms/linux/daemon/wireguardutilslinux.cpp \ 96 + --replace-fail 'm_tunnel.start(appPath.filePath("../../client/bin/wireguard-go"), wgArgs);' 'm_tunnel.start("${awg-vendored}/bin/amneziawg-go", wgArgs);' 97 substituteInPlace client/utilities.cpp \ 98 --replace-fail 'return Utils::executable("../../client/bin/openvpn", true);' 'return Utils::executable("${openvpn}/bin/openvpn", false);' \ 99 --replace-fail 'return Utils::executable("../../client/bin/tun2socks", true);' 'return Utils::executable("${amnezia-tun2socks}/bin/amnezia-tun2socks", false);' \ ··· 162 ''; 163 164 passthru = { 165 + inherit amnezia-tun2socks amnezia-xray awg-vendored; 166 updateScript = nix-update-script { 167 extraArgs = [ 168 "--subpackage" 169 "amnezia-tun2socks" 170 "--subpackage" 171 "amnezia-xray" 172 + "--subpackage" 173 + "awg-vendored" 174 ]; 175 }; 176 }; ··· 182 license = licenses.gpl3; 183 mainProgram = "AmneziaVPN"; 184 maintainers = with maintainers; [ sund3RRR ]; 185 + platforms = platforms.linux; 186 }; 187 })