blob: 612f647686f8c8690ad85f14edb4aaef1cb633c3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
{
buildPythonPackage,
fetchFromGitHub,
legacy-cgi,
lib,
pyopenssl,
pytestCheckHook,
requests,
}:
buildPythonPackage rec {
pname = "servefile";
version = "0.5.4";
format = "setuptools";
src = fetchFromGitHub {
owner = "sebageek";
repo = "servefile";
tag = "v${version}";
hash = "sha256-hIqXwhmvstCslsCO973oK5FF2c8gZJ0wNUI/z8W+OjU=";
};
dependencies = [
legacy-cgi
pyopenssl
];
nativeCheckInputs = [
pytestCheckHook
requests
];
# Test attempts to connect to a port on localhost which fails in nix build
# environment.
disabledTests = [
"test_abort_download"
"test_big_download"
"test_https_big_download"
"test_https"
"test_redirect_and_download"
"test_specify_port"
"test_upload_size_limit"
"test_upload"
];
pythonImportsCheck = [ "servefile" ];
meta = {
description = "Serve files from shell via a small HTTP server";
mainProgram = "servefile";
homepage = "https://github.com/sebageek/servefile";
license = lib.licenses.gpl3Plus;
maintainers = with lib.maintainers; [ samuela ];
};
}
|