Merge pull request #146236 from fabaff/tailscale

This commit is contained in:
Sandro 2021-11-17 03:51:16 +01:00 committed by GitHub
commit 82b5e86be8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 63 additions and 0 deletions

View file

@ -0,0 +1,61 @@
{ lib
, aiohttp
, aresponses
, buildPythonPackage
, fetchFromGitHub
, poetry-core
, pydantic
, pytest-asyncio
, pytestCheckHook
, pythonOlder
, yarl
}:
buildPythonPackage rec {
pname = "tailscale";
version = "0.1.2";
format = "pyproject";
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "frenck";
repo = "python-tailscale";
rev = "v${version}";
sha256 = "1jqx2i8rghfxlb1c76f37viz9fc1vq95xb2jm3bpnx5yy4n5dly1";
};
nativeBuildInputs = [
poetry-core
];
propagatedBuildInputs = [
aiohttp
pydantic
yarl
];
checkInputs = [
aresponses
pytest-asyncio
pytestCheckHook
];
postPatch = ''
# Upstream doesn't set a version for the pyproject.toml
substituteInPlace pyproject.toml \
--replace "0.0.0" "${version}" \
--replace "--cov" ""
'';
pythonImportsCheck = [
"tailscale"
];
meta = with lib; {
description = "Python client for the Tailscale API";
homepage = "https://github.com/frenck/python-wled";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}

View file

@ -9097,6 +9097,8 @@ in {
tailer = callPackage ../development/python-modules/tailer { };
tailscale = callPackage ../development/python-modules/tailscale { };
tappy = callPackage ../development/python-modules/tappy { };
tasklib = callPackage ../development/python-modules/tasklib { };