summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoman Prykhodchenko <me@romcheg.me>2016-02-18 17:24:24 +0100
committerRoman Prykhodchenko <me@romcheg.me>2016-02-18 17:52:58 +0100
commit3309949228cd80c3e954c3f11a9655a0eb4bc5d1 (patch)
treef36b1070305b6fa6f09d04b77b7deb7061237c6f
parentfc13d9a1a3e8c0da6f1b25a3bdf2a68ca5f5b1e3 (diff)
Synchronize with global requirements
This patch allignes both versions and order of packages in requirements.txt and test-requirements.txt with master revision of OpenStack's global requirements in Mitaka release cycle. In order to perform the soft sync all settings from setup.py were moved to setup.cfg and setup.py was autogenerated using cookiecutter and the default project template for OpenStack projects. Partial-bug: #1469045 Change-Id: I4486a6b5474b15fb2261c2642895064d80877618
Notes
Notes (review): Code-Review+1: Igor Kalnitsky <ikalnitsky@mirantis.com> Code-Review+1: Bulat Gaifullin <bgaifullin@mirantis.com> Code-Review+2: Dmitry Shulyak <dshulyak@mirantis.com> Workflow+1: Dmitry Shulyak <dshulyak@mirantis.com> Verified+2: Jenkins Submitted-by: Jenkins Submitted-at: Thu, 10 Mar 2016 12:41:08 +0000 Reviewed-on: https://review.openstack.org/281952 Project: openstack/network-checker Branch: refs/heads/master
-rw-r--r--CONTRIBUTING.rst17
-rw-r--r--HACKING.rst4
-rw-r--r--README.rst30
-rw-r--r--network_checker/hooks.py23
-rw-r--r--requirements.txt22
-rw-r--r--setup.cfg53
-rw-r--r--setup.py68
-rw-r--r--test-requirements.txt15
-rw-r--r--tox.ini7
9 files changed, 174 insertions, 65 deletions
diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst
new file mode 100644
index 0000000..d7317dd
--- /dev/null
+++ b/CONTRIBUTING.rst
@@ -0,0 +1,17 @@
1If you would like to contribute to the development of OpenStack, you must
2follow the steps in this page:
3
4 http://docs.openstack.org/infra/manual/developers.html
5
6If you already have a good understanding of how the system works and your
7OpenStack accounts are set up, you can skip to the development workflow
8section of this documentation to learn how changes to OpenStack should be
9submitted for review via the Gerrit tool:
10
11 http://docs.openstack.org/infra/manual/developers.html#development-workflow
12
13Pull requests submitted through GitHub will be ignored.
14
15Bugs should be filed on Launchpad, not GitHub:
16
17 https://bugs.launchpad.net/network-checker
diff --git a/HACKING.rst b/HACKING.rst
new file mode 100644
index 0000000..a229252
--- /dev/null
+++ b/HACKING.rst
@@ -0,0 +1,4 @@
1network-checker Style Commandments
2===============================================
3
4Read the OpenStack Style Commandments http://docs.openstack.org/developer/hacking/
diff --git a/README.rst b/README.rst
new file mode 100644
index 0000000..2c23a7c
--- /dev/null
+++ b/README.rst
@@ -0,0 +1,30 @@
1===============================
2network-checker
3===============================
4
5network-checker provides utilities for verifying a network setup. At this
6moment it is mainly used in `Fuel <https://github.com/stackforge/fuel-web>`_.
7
8
9-----------------
10Project resources
11-----------------
12
13Project status, bugs, and blueprints are tracked on Launchpad:
14 https://launchpad.net/fuel
15
16Development documentation is hosted here:
17 https://docs.fuel-infra.org/fuel-dev
18
19User guide can be found here:
20 http://docs.mirantis.com
21
22Any additional information can be found on the Fuel's project wiki
23 https://wiki.openstack.org/wiki/Fuel
24
25Anyone wishing to contribute to shotgun should follow the general
26OpenStack process. A good reference for it can be found here:
27 https://wiki.openstack.org/wiki/How_To_Contribute
28
29 http://docs.openstack.org/infra/manual/developers.html
30
diff --git a/network_checker/hooks.py b/network_checker/hooks.py
new file mode 100644
index 0000000..0ef8238
--- /dev/null
+++ b/network_checker/hooks.py
@@ -0,0 +1,23 @@
1# Copyright 2014 Mirantis, Inc.
2#
3# This program is free software; you can redistribute it and/or modify
4# it under the terms of the GNU General Public License as published by
5# the Free Software Foundation; either version 2 of the License, or
6# (at your option) any later version.
7#
8# This program is distributed in the hope that it will be useful,
9# but WITHOUT ANY WARRANTY; without even the implied warranty of
10# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11# GNU General Public License for more details.
12#
13# You should have received a copy of the GNU General Public License along
14# with this program; if not, write to the Free Software Foundation, Inc.,
15# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
16
17
18def setup_hook(config):
19 import pbr
20 import pbr.packaging
21
22 # this monkey patch is to avoid appending git version to version
23 pbr.packaging._get_version_from_git = lambda pre_version: pre_version
diff --git a/requirements.txt b/requirements.txt
index 94ce29a..634c4d5 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,9 +1,15 @@
1cliff-tablib 1# The order of packages is significant, because pip processes them in the order
2scapy==2.2.0-dev 2# of appearance. Changing the order has an impact on the overall integration
3pypcap==1.1.1 3# process, which may cause wedges in the gate later.
4stevedore 4cliff-tablib>=1.0 # Apache-2.0
5stevedore>=1.5.0 # Apache-2.0
6PyYAML>=3.1.0 # MIT
7requests!=2.9.0,>=2.8.1 # Apache-2.0
8netifaces>=0.10.4 # MIT
9six>=1.9.0 # MIT
10
11# Packages beyond this line are not in Global Requirements list
12# and must be added there or replaced.
5daemonize 13daemonize
6pyyaml 14pypcap>=1.1.1
7requests 15scapy>=2.2.0-dev
8netifaces
9six
diff --git a/setup.cfg b/setup.cfg
new file mode 100644
index 0000000..c45253c
--- /dev/null
+++ b/setup.cfg
@@ -0,0 +1,53 @@
1[metadata]
2name = network-checker
3version = 9.0.0
4summary = Command line utilities for performing network verification
5author = Mirantis Inc.
6author-email = product@mirantis.com
7home-page = http://mirantis.com
8description-file =
9 README.rst
10classifier =
11 Environment :: OpenStack
12 Intended Audience :: Information Technology
13 Intended Audience :: System Administrators
14 License :: OSI Approved :: GNU General Public License v2 (GPLv2)
15 Operating System :: POSIX :: Linux
16 Programming Language :: Python
17 Programming Language :: Python :: 2
18 Programming Language :: Python :: 2.7
19
20[files]
21packages =
22 dhcp_checker
23 fuel_network_checker
24 network_checker
25 url_access_checker
26
27[entry_points]
28console_scripts =
29 net_probe.py=network_checker.net_check.api:main
30 fuel-netcheck=network_checker.cli:main
31 dhcpcheck=dhcp_checker.cli:main
32 urlaccesscheck=url_access_checker.cli:main
33
34dhcp.check =
35 discover=dhcp_checker.commands:ListDhcpServers
36 request=dhcp_checker.commands:ListDhcpAssignment
37 vlans=dhcp_checker.commands:DhcpWithVlansCheck
38
39network_checker =
40 multicast=network_checker.multicast.api:MulticastChecker
41 simple=network_checker.tests.simple:SimpleChecker
42
43urlaccesscheck =
44 check=url_access_checker.commands:CheckUrls
45 with_setup=url_access_checker.commands:CheckUrlsWithSetup
46
47[global]
48setup-hooks =
49 pbr.hooks.setup_hook
50 network_checker.hooks.setup_hook
51
52[wheel]
53python-tag = py2
diff --git a/setup.py b/setup.py
index 3b471db..782bb21 100644
--- a/setup.py
+++ b/setup.py
@@ -1,55 +1,29 @@
1# Copyright 2014 Mirantis, Inc. 1# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
2# 2#
3# This program is free software; you can redistribute it and/or modify 3# Licensed under the Apache License, Version 2.0 (the "License");
4# it under the terms of the GNU General Public License as published by 4# you may not use this file except in compliance with the License.
5# the Free Software Foundation; either version 2 of the License, or 5# You may obtain a copy of the License at
6# (at your option) any later version.
7# 6#
8# This program is distributed in the hope that it will be useful, 7# http://www.apache.org/licenses/LICENSE-2.0
9# but WITHOUT ANY WARRANTY; without even the implied warranty of
10# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11# GNU General Public License for more details.
12# 8#
13# You should have received a copy of the GNU General Public License along 9# Unless required by applicable law or agreed to in writing, software
14# with this program; if not, write to the Free Software Foundation, Inc., 10# distributed under the License is distributed on an "AS IS" BASIS,
15# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
12# implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
16 15
16# THIS FILE IS MANAGED BY THE GLOBAL REQUIREMENTS REPO - DO NOT EDIT
17import setuptools 17import setuptools
18 18
19# In python < 2.7.4, a lazy loading of package `pbr` will break
20# setuptools if some other modules registered functions in `atexit`.
21# solution from: http://bugs.python.org/issue15881#msg170215
22try:
23 import multiprocessing # noqa
24except ImportError:
25 pass
19 26
20setuptools.setup( 27setuptools.setup(
21 name="network-checker", 28 setup_requires=['pbr>=1.8'],
22 version='9.0.0', 29 pbr=True)
23 author="Mirantis Inc",
24 classifiers=[
25 "License :: OSI Approved :: Apache 2.0",
26 "Development Status :: 5 - Production/Stable",
27 "Environment :: Console",
28 "Operating System :: POSIX",
29 "Programming Language :: Python",
30 "Topic :: Software Development :: Testing"
31 ],
32 include_package_data=True,
33 packages=setuptools.find_packages(),
34 entry_points={
35 'console_scripts': [
36 'net_probe.py = network_checker.net_check.api:main',
37 'fuel-netcheck = network_checker.cli:main',
38 'dhcpcheck = dhcp_checker.cli:main',
39 'urlaccesscheck = url_access_checker.cli:main',
40 ],
41 'dhcp.check': [
42 'discover = dhcp_checker.commands:ListDhcpServers',
43 'request = dhcp_checker.commands:ListDhcpAssignment',
44 'vlans = dhcp_checker.commands:DhcpWithVlansCheck'
45 ],
46 'network_checker': [
47 'multicast = network_checker.multicast.api:MulticastChecker',
48 'simple = network_checker.tests.simple:SimpleChecker'
49 ],
50 'urlaccesscheck': [
51 'check = url_access_checker.commands:CheckUrls',
52 'with_setup = url_access_checker.commands:CheckUrlsWithSetup'
53 ],
54 },
55)
diff --git a/test-requirements.txt b/test-requirements.txt
index 3b89e32..6f8239c 100644
--- a/test-requirements.txt
+++ b/test-requirements.txt
@@ -1,6 +1,11 @@
1-r requirements.txt 1# The order of packages is significant, because pip processes them in the order
2hacking==0.7 2# of appearance. Changing the order has an impact on the overall integration
3mock==1.0.1 3# process, which may cause wedges in the gate later.
4hacking<0.11,>=0.10.2 # Apache-2.0
5mock>=1.2 # BSD
6unittest2 # BSD
7requests-mock>=0.7.0 # Apache-2.0
8
9# Packages beyond this line are not in Global Requirements list
10# and must be added there or replaced.
4pytest 11pytest
5unittest2
6requests-mock
diff --git a/tox.ini b/tox.ini
index 6c7502d..06a00eb 100644
--- a/tox.ini
+++ b/tox.ini
@@ -5,14 +5,12 @@ envlist = py27,pep8
5 5
6[testenv] 6[testenv]
7usedevelop = True 7usedevelop = True
8install_command = pip install --allow-external -U {opts} {packages}
9setenv = VIRTUAL_ENV={envdir} 8setenv = VIRTUAL_ENV={envdir}
10deps = -r{toxinidir}/test-requirements.txt 9deps = -r{toxinidir}/requirements.txt
10 -r{toxinidir}/test-requirements.txt
11commands = py.test {toxinidir}/url_access_checker/tests 11commands = py.test {toxinidir}/url_access_checker/tests
12 12
13[testenv:pep8] 13[testenv:pep8]
14deps = hacking==0.10
15usedevelop = False
16commands = 14commands =
17 flake8 {posargs:.} 15 flake8 {posargs:.}
18 16
@@ -24,7 +22,6 @@ envdir = devenv
24usedevelop = True 22usedevelop = True
25 23
26[flake8] 24[flake8]
27ignore = H234,H302,H802
28exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools,__init__.py,docs 25exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools,__init__.py,docs
29show-pep8 = True 26show-pep8 = True
30show-source = True 27show-source = True