1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/setup.py
Toshio Kuratomi 17f134ca02 distutils' requires parameter doesn't work with setuptools. Use
setuptools' instal_requires instead
2014-03-14 12:38:01 -07:00

57 lines
1.7 KiB
Python

#!/usr/bin/env python
import os
import sys
from glob import glob
sys.path.insert(0, os.path.abspath('lib'))
from ansible import __version__, __author__
from setuptools import setup
# find library modules
from ansible.constants import DEFAULT_MODULE_PATH
module_paths = DEFAULT_MODULE_PATH.split(os.pathsep)
# always install in /usr/share/ansible if specified
# otherwise use the first module path listed
if '/usr/share/ansible' in module_paths:
install_path = '/usr/share/ansible'
else:
install_path = module_paths[0]
dirs=os.listdir("./library/")
data_files = []
for i in dirs:
data_files.append((os.path.join(install_path, i), glob('./library/' + i + '/*')))
setup(name='ansible',
version=__version__,
description='Radically simple IT automation',
author=__author__,
author_email='michael@ansible.com',
url='http://ansible.com/',
license='GPLv3',
install_requires=['paramiko', 'jinja2', "PyYAML", 'setuptools', 'pycrypto >= 2.6'],
package_dir={ 'ansible': 'lib/ansible' },
packages=[
'ansible',
'ansible.utils',
'ansible.inventory',
'ansible.inventory.vars_plugins',
'ansible.playbook',
'ansible.runner',
'ansible.runner.action_plugins',
'ansible.runner.lookup_plugins',
'ansible.runner.connection_plugins',
'ansible.runner.filter_plugins',
'ansible.callback_plugins',
'ansible.module_utils'
],
scripts=[
'bin/ansible',
'bin/ansible-playbook',
'bin/ansible-pull',
'bin/ansible-doc',
'bin/ansible-galaxy',
'bin/ansible-vault',
],
data_files=data_files
)