apevec pushed to openstack-packstack (f22). "Explicitly set MongoDB config file (..more)"
notifications at fedoraproject.org
notifications at fedoraproject.org
Wed Apr 22 10:00:31 UTC 2015
>From 6c41100df969749d8a2fb0a938060d2bdd8006c8 Mon Sep 17 00:00:00 2001
From: Alan Pevec <alan.pevec at redhat.com>
Date: Wed, 22 Apr 2015 11:59:10 +0200
Subject: Explicitly set MongoDB config file
https://bugzilla.redhat.com/show_bug.cgi?id=1212174
Change-Id: Ia0cbb6756a533ac5b5e3d814fdac7d7b28eaa56d
diff --git a/0001-Explicitly-set-MongoDB-config-file.patch b/0001-Explicitly-set-MongoDB-config-file.patch
new file mode 100644
index 0000000..e83920e
--- /dev/null
+++ b/0001-Explicitly-set-MongoDB-config-file.patch
@@ -0,0 +1,55 @@
+From 3ff9704d28789ef8519d4e8a69248e4f156a885f Mon Sep 17 00:00:00 2001
+From: Javier Pena <jpena at redhat.com>
+Date: Thu, 16 Apr 2015 12:47:06 +0200
+Subject: [PATCH] Explicitly set MongoDB config file
+
+Depending on the combination of Linux and OpenStack distros, we
+now have different configuration files for MongoDB. Given it can
+create issues because different mongodb-server 2.6 packages have
+different configuration files, we are explicitly defining the
+config file name:
+
+- Fedora 21 with RDO: /etc/mongodb.conf
+- CentOS 7 and RHEL 7 with EPEL and RDO: /etc/mongod.conf
+- RHEL 7 with RHEL OSP: /etc/mongodb.conf
+
+The differences also affect the sharding configuration file
+(mongos.conf or mongodb-shard.conf), but Packstack does not
+configure sharding.
+
+Cherry-picked from 6ad268f49a263600a40d4720b3fa66957527524b
+
+Fixes: rhbz#1212174
+Change-Id: If138a5bcd916856090b2716bc17d5e910fa325ee
+---
+ packstack/puppet/templates/mongodb.pp | 14 +++++++++++++-
+ 1 file changed, 13 insertions(+), 1 deletion(-)
+
+diff --git a/packstack/puppet/templates/mongodb.pp b/packstack/puppet/templates/mongodb.pp
+index 5343400..054656a 100644
+--- a/packstack/puppet/templates/mongodb.pp
++++ b/packstack/puppet/templates/mongodb.pp
+@@ -1,7 +1,19 @@
+ $mongodb_host = hiera('CONFIG_MONGODB_HOST')
++$use_epel = hiera('CONFIG_USE_EPEL')
++
++# The MongoDB config files differ between versions
++if (($::operatingsystem == 'fedora' and versioncmp($::operatingsystemrelease, '22') >= 0)
++ or
++ ($::operatingsystem != 'fedora' and versioncmp($::operatingsystemrelease, '7.0') >= 0 and $use_epel == 'y')
++ ){
++ $config_file = '/etc/mongod.conf'
++} else {
++ $config_file = '/etc/mongodb.conf'
++}
+
+ class { 'mongodb::server':
+ smallfiles => true,
+- bind_ip => [$mongodb_host],
++ bind_ip => $mongodb_host,
++ config => $config_file,
+ }
+
+--
+1.9.3
+
diff --git a/openstack-packstack.spec b/openstack-packstack.spec
index 5c1a644..ff9a341 100644
--- a/openstack-packstack.spec
+++ b/openstack-packstack.spec
@@ -6,7 +6,7 @@
Name: openstack-packstack
Version: 2014.2
-Release: 0.22.dev%{git_snaptag}.%{git_commit}%{?dist}
+Release: 0.23.dev%{git_snaptag}.%{git_commit}%{?dist}
Summary: Openstack Install Utility
Group: Applications/System
@@ -14,6 +14,7 @@ License: ASL 2.0 and GPLv2
URL: https://github.com/stackforge/packstack
# Tarball is created by bin/release.sh
Source0: http://mmagr.fedorapeople.org/downloads/packstack/packstack-%{version}.dev%{git_snaptag}.%{git_commit}.tar.gz
+Patch0: 0001-Explicitly-set-MongoDB-config-file.patch
BuildArch: noarch
@@ -67,6 +68,7 @@ This package contains documentation files for Packstack.
%prep
#%setup -n packstack-%{version}dev%{git_revno}
%setup -n packstack-%{version}.dev%{git_snaptag}.%{git_commit}
+%patch0 -p1
# Sanitizing a lot of the files in the puppet modules
find packstack/puppet/modules \( -name .fixtures.yml -o -name .gemfile -o -name ".travis.yml" -o -name .rspec \) -exec rm {} +
@@ -140,6 +142,9 @@ install -p -D -m 644 docs/_build/man/*.1 %{buildroot}%{_mandir}/man1/
# changelog --------------------------------------------------------------------
%changelog
+* Wed Apr 22 2015 Alan Pevec <apevec at redhat.com> - 2014.2-0.23.dev1468
+- Explicitly set MongoDB config file rhbz#1212174
+
* Thu Apr 16 2015 Lukas Bezdicka <lbezdick at redhat.com> - 2014.2-0.22.dev1468
- [Keystone] puppet-keystone support the ldap user_enabled_invert parameter (rhbz#1205768)
--
cgit v0.10.2
http://pkgs.fedoraproject.org/cgit/openstack-packstack.git/commit/?h=f22&id=6c41100df969749d8a2fb0a938060d2bdd8006c8
More information about the scm-commits
mailing list