Skip to content

Commit

Permalink
Use PyPi packages for ceph python bindings
Browse files Browse the repository at this point in the history
Ceph python bindings are now available from pypi, so they can be
installed within a venv. Previously we were relying on the bindings
being installed via an apt package and symlinking out of the relevant
venvs into site packages.

This commit also includes a revert for the commit that introduced the
symlinks:

Revert "Symlink ceph libraries out of venv"

This reverts commit a0ab6f7a6efea1dabf5ac006f766c17596a0d10b.

Ceph Bug: http://tracker.ceph.com/issues/5900
Related-Bug: #1509837
Package URL: https://pypi.python.org/pypi/python-cephlibs/0.94.5.post1

Change-Id: Id8a0b8ea810fd9e43f9743bb2572e2b6b0985230
  • Loading branch information
hughsaunders authored and Jesse Pretorius committed Dec 2, 2015
1 parent 84adf9d commit 1f63049
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 22 deletions.
1 change: 1 addition & 0 deletions defaults/main.yml
Expand Up @@ -312,6 +312,7 @@ nova_pip_packages:
- python-novaclient
- keystonemiddleware
- nova
- python-cephlibs


## Tunable overrides
Expand Down
22 changes: 0 additions & 22 deletions tasks/nova_compute_kvm_install.yml
Expand Up @@ -77,28 +77,6 @@
- nova-install
- nova-pip-packages

# TODO(mattt): remove once ceph_client role can install ceph packages from pypi
# This is being done as a temporary workaround since we currently cannot obtain
# ceph-related libraries from pypi. There is work in progress [1] to address
# this.
# [1] http://tracker.ceph.com/issues/5900
- name: Link ceph libraries into the venv
file:
src: "{{ item.name }}"
dest: "{{ nova_venv_bin | dirname }}/lib/python2.7/site-packages/{{ item.name | basename }}"
state: "{{ item.state }}"
force: "yes"
with_items:
- { state: link, name: "/usr/lib/python2.7/dist-packages/rados.py" }
- { state: link, name: "/usr/lib/python2.7/dist-packages/rbd.py" }
when:
- nova_venv_enabled | bool
- inventory_hostname in groups['nova_compute']
- (cinder_backends_rbd_inuse|bool or nova_libvirt_images_rbd_pool is defined)
tags:
- nova-install
- nova-pip-packages

- name: Install pip packages (no venv)
pip:
name: "{{ item }}"
Expand Down

0 comments on commit 1f63049

Please sign in to comment.