1
0
mirror of https://github.com/ansible/awx.git synced 2024-10-30 22:21:13 +03:00
awx/requirements
Shane McDonald dfdf59bcf5 Fix RPM builds
The version of setuptools bundled with virtualenv is broken. This fixes things for both online and offline pip installs.
2017-05-11 14:26:52 -04:00
..
README.md Dependency Updates 2017-05-08 12:03:02 -04:00
requirements_ansible_git.txt add pyparsing a top level dep and fix other deps 2017-04-03 16:17:05 -04:00
requirements_ansible_uninstall.txt uninstall certifi if installed in venv's 2016-12-14 09:53:24 -05:00
requirements_ansible.in Dependency Updates 2017-05-08 12:03:02 -04:00
requirements_ansible.txt Dependency Updates 2017-05-08 12:03:02 -04:00
requirements_dev_uninstall.txt uninstall certifi if installed in venv's 2016-12-14 09:53:24 -05:00
requirements_dev.txt Fix ipython version in dev container to 5.2.1 2017-04-26 09:57:51 -04:00
requirements_git.txt add pyparsing a top level dep and fix other deps 2017-04-03 16:17:05 -04:00
requirements_setup_requires.txt Fix RPM builds 2017-05-11 14:26:52 -04:00
requirements_tower_uninstall.txt uninstall certifi if installed in venv's 2016-12-14 09:53:24 -05:00
requirements.in Dependency Updates 2017-05-08 12:03:02 -04:00
requirements.txt Dependency Updates 2017-05-08 12:03:02 -04:00

The requirements.txt and requirements_ansible.txt files are generated from requirements.in and requirements_ansible.in, respectively, using pip-tools pip-compile. The following commands should do this if ran inside the tower_tools container.

NOTE: before running pip-compile, please copy-paste contents in requirements/requirements_git.txt to the top of requirements/requirements.in and prepend each copied line with -e . Later after requirements.txt is generated, don't forget to remove all git+https://github.com...-like lines from both requirements.txt and requirements.in

virtualenv /buildit
source /buildit/bin/activate
pip install pip-tools
pip install pip --upgrade

pip-compile requirements/requirements.in > requirements/requirements.txt
pip-compile requirements/requirements_ansible.in > requirements/requirements_ansible.txt

Known Issues

  • Remove the -e from packages of the form -e git+https://github.com... in the generated .txt. Failure to do so will result in a "bad" RPM and DEB due to the pip install laying down a symbolic link with an absolute path from the virtualenv to the git repository that will differ from when the RPM and DEB are build to when the RPM and DEB are installed on a machine. By removing the -e the symbolic egg link will not be created and all is well.

  • As of pip-tools 1.8.1 pip-compile does not resolve packages specified using a git url. Thus, dependencies for things like dm.xmlsec.binding do not get resolved and output to requirements.txt. This means that:

    • can't use pip install --no-deps because other deps WILL be sucked in
    • all dependencies are NOT captured in our .txt files. This means you can't rely on the .txt when gathering licenses.
  • Packages gevent-websocket and twisted are put in requirements.in not because they are primary dependency of Tower, but because their versions needs to be freezed as dependencies of django channel. Please be mindful when doing dependency updates.