proton-vpn-killswitch-network-manager-wireguard: init at 0.1.4
This commit is contained in:
+64
@@ -0,0 +1,64 @@
|
||||
{
|
||||
lib,
|
||||
buildPythonPackage,
|
||||
fetchFromGitHub,
|
||||
gobject-introspection,
|
||||
setuptools,
|
||||
networkmanager,
|
||||
proton-vpn-api-core,
|
||||
proton-vpn-killswitch,
|
||||
proton-vpn-logger,
|
||||
pycairo,
|
||||
pygobject3,
|
||||
pytestCheckHook,
|
||||
iproute2,
|
||||
pytest-cov-stub,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "proton-vpn-killswitch-network-manager-wireguard";
|
||||
version = "0.1.4";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "ProtonVPN";
|
||||
repo = "python-proton-vpn-killswitch-network-manager-wireguard";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-4sYD2X1U066FMjrtbTb31wvkCDWAw+eXod+pi0gGsCQ=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
# Solves ImportError: cannot import name NM, introspection typelib not found
|
||||
gobject-introspection
|
||||
setuptools
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
# Needed here for the NM namespace
|
||||
networkmanager
|
||||
proton-vpn-api-core
|
||||
proton-vpn-killswitch
|
||||
proton-vpn-logger
|
||||
pycairo
|
||||
pygobject3
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace proton/vpn/killswitch/backend/linux/wireguard/killswitch_connection_handler.py \
|
||||
--replace '/usr/sbin/ip' '${iproute2}/bin/ip'
|
||||
'';
|
||||
|
||||
pythonImportsCheck = [ "proton.vpn.killswitch.backend.linux.wireguard" ];
|
||||
|
||||
nativeCheckInputs = [
|
||||
pytestCheckHook
|
||||
pytest-cov-stub
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "Implementation of the proton-vpn-killswitch interface using Network Manager with wireguard-protocol";
|
||||
homepage = "https://github.com/ProtonVPN/proton-vpn-killswitch-network-manager-wireguard";
|
||||
license = lib.licenses.gpl3Only;
|
||||
maintainers = with lib.maintainers; [ sebtm ];
|
||||
};
|
||||
}
|
||||
@@ -10607,6 +10607,8 @@ self: super: with self; {
|
||||
|
||||
proton-vpn-killswitch-network-manager = callPackage ../development/python-modules/proton-vpn-killswitch-network-manager { };
|
||||
|
||||
proton-vpn-killswitch-network-manager-wireguard = callPackage ../development/python-modules/proton-vpn-killswitch-network-manager-wireguard { };
|
||||
|
||||
proton-vpn-logger = callPackage ../development/python-modules/proton-vpn-logger { };
|
||||
|
||||
proton-vpn-network-manager = callPackage ../development/python-modules/proton-vpn-network-manager { };
|
||||
|
||||
Reference in New Issue
Block a user