Skip to content

Commit

Permalink
Fix Gnocchi support ceph
Browse files Browse the repository at this point in the history
Based on gnocchi issue #412 [0], cradox is more stable and recommended
to use.

* Add cradox for source and  RHEL family distro binary.
* Ubuntu binary lacks of cradox package, so install from pypi

[0] gnocchixyz/gnocchi#412

Co-Authored-By: Jeffrey Zhang <zhang.lei.fly@gmail.com>
Change-Id: Icf7d6425884fb889d48c786caebbfc7b7050ae8e
Closes-Bug: #1718701
  • Loading branch information
faridda and jeffrey4l committed Nov 28, 2017
1 parent 781c106 commit 24f1714
Showing 1 changed file with 15 additions and 7 deletions.
22 changes: 15 additions & 7 deletions docker/gnocchi/gnocchi-base/Dockerfile.j2
Expand Up @@ -16,7 +16,7 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
'mod_wsgi',
'openstack-gnocchi-common',
'python-ldappool',
'python-rados'
'python2-cradox'
] %}

{{ macros.install_packages(gnocchi_base_packages | customizable("packages")) }}
Expand All @@ -26,25 +26,33 @@ RUN sed -i -r 's,^(Listen 80),#\1,' /etc/httpd/conf/httpd.conf \

{% set gnocchi_base_packages = [
'apache2',
'build-essential',
'gnocchi-common',
'libapache2-mod-wsgi',
'librados-dev',
'python-dev',
'python-ldappool',
'python-rados'
'python-rados',
'python-setuptools'
] %}
{% set gnocchi_base_pip_packages = [
'cradox'
] %}

{{ macros.install_packages(gnocchi_base_packages | customizable("packages")) }}
RUN truncate -s 0 /etc/apache2/ports.conf
RUN {{ macros.install_pip(gnocchi_base_pip_packages | customizable("pip_packages"), constraints=false) }} \
&& truncate -s 0 /etc/apache2/ports.conf

{% endif %}
{% elif install_type == 'source' %}
{% if base_distro in ['centos', 'oraclelinux', 'rhel'] %}

{% set gnocchi_base_packages = [
'httpd',
'librados2-devel',
'mod_ssl',
'mod_wsgi',
'python-ldappool',
'python-rados'
'python-ldappool'
] %}

# on x86-64 pip grabs precompiled numpy/scipy - on aarch64/ppc64le
Expand All @@ -66,8 +74,8 @@ RUN mkdir -p /var/www/cgi-bin/gnocchi \
{% set gnocchi_base_packages = [
'apache2',
'libapache2-mod-wsgi',
'python-ldappool',
'python-rados'
'librados-dev',
'python-ldappool'
] %}

# on x86-64 pip grabs precompiled numpy/scipy - on aarch64/ppc64le
Expand Down

0 comments on commit 24f1714

Please sign in to comment.