...
1# Copyright 2018 Datawire. All rights reserved.
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License
14
15import os
16
17from setuptools import find_packages, setup
18
19# from ambassador.VERSION import Version
20Version = "0.0.0-dev"
21
22requirements = open("requirements.txt", "r").read().split("\n")
23
24
25def collect_data_files(dirpath):
26 return [
27 (subdirpath, [os.path.join(subdirpath, filename) for filename in filenames])
28 for subdirpath, folders, filenames in os.walk(dirpath)
29 ]
30
31
32template_files = collect_data_files("templates")
33schema_files = collect_data_files("schemas")
34kat_files = [
35 (
36 subdirpath,
37 [os.path.join(subdirpath, filename) for filename in filenames if filename.endswith("go")],
38 )
39 for subdirpath, folders, filenames in os.walk("kat")
40]
41
42data_files = [("", ["ambassador.version"])] + template_files + schema_files + kat_files
43
44setup(
45 name="ambassador",
46 # version=versioneer.get_version(),
47 # cmdclass=versioneer.get_cmdclass(),
48 version=Version,
49 packages=find_packages(exclude=["tests"]),
50 # include_package_data=True,
51 install_requires=requirements,
52 data_files=data_files,
53 entry_points={
54 "console_scripts": [
55 "ambassador=ambassador_cli.ambassador:main",
56 "diagd=ambassador_diag.diagd:main",
57 "mockery=ambassador_cli.mockery:main",
58 "grab-snapshots=ambassador_cli.grab_snapshots:main",
59 "ert=ambassador_cli.ert:main",
60 ]
61 },
62 author="datawire.io",
63 author_email="dev@datawire.io",
64 url="https://www.getambassador.io",
65 download_url="https://github.com/datawire/ambassador",
66 keywords=["kubernetes", "microservices", "api gateway", "envoy", "ambassador"],
67 classifiers=[],
68)
View as plain text