| garciadeblas | cd520d3 | 2017-03-09 16:28:59 +0100 | [diff] [blame] | 1 | #!/usr/bin/env python |
| 2 | |
| garciadeblas | 06e6c39 | 2017-03-28 15:42:20 +0200 | [diff] [blame] | 3 | from setuptools import setup |
| garciadeblas | 2c290ca | 2017-04-06 03:12:51 +0200 | [diff] [blame^] | 4 | from setuptools.command.install import install |
| 5 | from os import system |
| garciadeblas | cd520d3 | 2017-03-09 16:28:59 +0100 | [diff] [blame] | 6 | #import glob |
| 7 | |
| garciadeblas | 2c290ca | 2017-04-06 03:12:51 +0200 | [diff] [blame^] | 8 | _name = 'osm_ro' |
| 9 | _version = '1.0.0' |
| 10 | _description = 'OSM Resource Orchestrator' |
| 11 | _author = 'ETSI OSM' |
| 12 | _author_email = 'alfonso.tiernosepulveda@telefonica.com' |
| 13 | _maintainer = 'garciadeblas' |
| 14 | _maintainer_email = 'gerardo.garciadeblas@telefonica.com' |
| 15 | _license = 'Apache 2.0' |
| 16 | _url = 'https://osm.etsi.org/gitweb/?p=osm/RO.git;a=summary' |
| 17 | _requirements = [ |
| garciadeblas | 06e6c39 | 2017-03-28 15:42:20 +0200 | [diff] [blame] | 18 | "PyYAML", |
| 19 | "bottle", |
| garciadeblas | 2c290ca | 2017-04-06 03:12:51 +0200 | [diff] [blame^] | 20 | "MySQL-python", |
| garciadeblas | 06e6c39 | 2017-03-28 15:42:20 +0200 | [diff] [blame] | 21 | "jsonschema", |
| 22 | "paramiko", |
| 23 | "argcomplete", |
| 24 | "requests", |
| 25 | "logutils", |
| garciadeblas | 2c290ca | 2017-04-06 03:12:51 +0200 | [diff] [blame^] | 26 | "python-novaclient", |
| 27 | "python-keystoneclient", |
| 28 | "python-glanceclient", |
| 29 | "python-neutronclient", |
| 30 | "python-cinderclient", |
| garciadeblas | 06e6c39 | 2017-03-28 15:42:20 +0200 | [diff] [blame] | 31 | "pyvcloud", |
| 32 | "progressbar", |
| 33 | "prettytable", |
| 34 | "pyvmomi", |
| garciadeblas | 2c290ca | 2017-04-06 03:12:51 +0200 | [diff] [blame^] | 35 | "boto", |
| garciadeblas | 06e6c39 | 2017-03-28 15:42:20 +0200 | [diff] [blame] | 36 | ] |
| 37 | |
| garciadeblas | 2c290ca | 2017-04-06 03:12:51 +0200 | [diff] [blame^] | 38 | class ROInstaller(install): |
| 39 | def run(self): |
| 40 | cmd = 'echo "Running install script"' |
| 41 | system(cmd) |
| 42 | install.run(self) |
| 43 | |
| 44 | setup(name=_name, |
| 45 | version = _version, |
| 46 | description = _description, |
| 47 | long_description = open('README.rst').read(), |
| 48 | author = _author, |
| 49 | author_email = _author_email, |
| 50 | maintainer = _maintainer, |
| 51 | maintainer_email = _maintainer_email, |
| 52 | url = _url, |
| 53 | license = _license, |
| 54 | packages = [_name], |
| 55 | #packages = ['osm_ro', 'osm_roclient'], |
| 56 | package_dir = {_name: _name}, |
| 57 | package_data = {_name: ['vnfs/*.yaml', 'vnfs/examples/*.yaml', |
| 58 | 'scenarios/*.yaml', 'scenarios/examples/*.yaml', |
| 59 | 'instance-scenarios/examples/*.yaml', 'database_utils/*', |
| 60 | 'scripts/install-openmano*.sh']}, |
| 61 | data_files = [('/etc/osm/', ['openmanod.cfg']), |
| 62 | ('/etc/systemd/system/', ['osm-ro.service']), |
| 63 | ], |
| 64 | scripts=['openmanod.py', 'openmano', 'osm_ro/scripts/service-openmano.sh', 'osm_ro/scripts/openmano-report.sh',], |
| 65 | install_requires=_requirements, |
| 66 | include_package_data=True, |
| 67 | cmdclass = {'install': ROInstaller}, |
| 68 | ) |
| garciadeblas | cd520d3 | 2017-03-09 16:28:59 +0100 | [diff] [blame] | 69 | |