-
Notifications
You must be signed in to change notification settings - Fork 12
/
setup.py
63 lines (56 loc) · 2.04 KB
/
setup.py
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
54
55
56
57
58
59
60
61
62
63
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""The setup script."""
from glob import glob
from os.path import abspath, basename, dirname, join, splitext
from setuptools import find_packages, setup
with open("README.rst") as readme_file:
readme = readme_file.read()
with open("version.txt") as f:
version = f.read().rstrip()
here = abspath(dirname(__file__))
# We're using a pip8 style requirements file, which allows us to embed hashes
# of the packages in it. However, setuptools doesn't support parsing this type
# of file, so we need to strip those out before passing the requirements along
# to it.
with open(join(here, "requirements", "base.txt")) as f:
requirements = []
for line in f:
# Skip empty and comment lines
if not line.strip() or line.strip().startswith("#"):
continue
# Skip lines with hash values
if not line.strip().startswith("--"):
requirements.append(line.split(";")[0].split()[0])
requirement_without_python_filter = line.split(";")[0]
requirement_without_trailing_characters = requirement_without_python_filter.split()[0]
setup(
author="Rail Aliiev",
author_email="[email protected]",
classifiers=[
"Development Status :: 2 - Pre-Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: Mozilla Public License 2.0 (MPL 2.0)"
"Natural Language :: English",
"Programming Language :: Python :: 3",
],
description="Autoscale scriptworkers in Kubernetes",
install_requires=requirements,
license="MPL2.0",
long_description=readme,
include_package_data=True,
keywords="k8s-autoscale",
name="k8s_autoscale",
packages=find_packages("src"),
package_dir={"": "src"},
test_suite="tests",
url="https://github.com/mozilla-releng/k8s-autoscale",
version=version,
zip_safe=False,
entry_points={
"console_scripts": [
"k8s_autoscale=k8s_autoscale.cli:main",
"k8s_autoscale-verify=k8s_autoscale.cli:verify",
]
},
)