2c873a44 |
#!/usr/bin/env python
|
3f245498 |
import os
import sys |
eee2d1af |
from glob import glob |
3f245498 |
|
f3a4705a |
sys.path.insert(0, os.path.abspath('lib')) |
3f245498 |
from ansible import __version__, __author__ |
e6220748 |
try:
from setuptools import setup
except ImportError: |
8e66a6c8 |
print "Ansible now needs setuptools in order to build. " + \
"Install it using your package manager (usually python-setuptools) or via pip (pip install setuptools)."
sys.exit(1) |
2c873a44 |
|
f3a4705a |
# find library modules
from ansible.constants import DEFAULT_MODULE_PATH |
b73a8efb |
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] |
f3a4705a |
dirs=os.listdir("./library/") |
17586baf |
data_files = [] |
f3a4705a |
for i in dirs: |
4310fc26 |
data_files.append((os.path.join(install_path, i), glob('./library/' + i + '/*'))) |
eee2d1af |
|
2c873a44 |
setup(name='ansible', |
3f245498 |
version=__version__, |
4a3b762a |
description='Radically simple IT automation', |
3f245498 |
author=__author__, |
d07a3b5e |
author_email='michael@ansible.com',
url='http://ansible.com/', |
47aa018a |
license='GPLv3', |
0fefab66 |
install_requires=['paramiko', 'jinja2', "PyYAML", 'setuptools', 'pycrypto >= 2.6'], |
f3a4705a |
package_dir={ 'ansible': 'lib/ansible' }, |
2c873a44 |
packages=[
'ansible', |
000d3832 |
'ansible.utils', |
6735733e |
'ansible.utils.module_docs_fragments', |
0f7ab7cb |
'ansible.inventory', |
7d7ff9d6 |
'ansible.inventory.vars_plugins', |
0f7ab7cb |
'ansible.playbook',
'ansible.runner', |
95540f40 |
'ansible.runner.action_plugins', |
dd3beb84 |
'ansible.runner.lookup_plugins', |
f264f50f |
'ansible.runner.connection_plugins', |
67321a60 |
'ansible.runner.filter_plugins', |
f264f50f |
'ansible.callback_plugins', |
ad5731b4 |
'ansible.module_utils' |
2c873a44 |
],
scripts=[
'bin/ansible', |
04ff248c |
'bin/ansible-playbook', |
17f31a2a |
'bin/ansible-pull', |
dc40c406 |
'bin/ansible-doc', |
ad687fce |
'bin/ansible-galaxy',
'bin/ansible-vault', |
eee2d1af |
],
data_files=data_files |
2c873a44 |
) |