919da082af
Problem: - Centos 7.5 upgraded puppet-cephs. - Porting of puppet-cephs patches did not resolve and 'fuzz' in the line numbers of the patches. - If puppet-ceph is built by rpm 4.11, or default version of rpm until 4.14 is compiled, a fuzzy patch results in the creating of an .orig file. - Packaging of puppet-cephs failes due to the unexpected, and unpackaged .orig file Solution: Safest solution is to de-fuzz our puppet-cephs patches. Story: 2003389 Task: 26755 Change-Id: I479131bd9aa5d1d8149912851180c40522ac6b1a Signed-off-by: Sun Austin <austin.sun@intel.com>
111 lines
4.0 KiB
Diff
111 lines
4.0 KiB
Diff
From c9a5520620d313c08e7f751f3469ec5f4c220486 Mon Sep 17 00:00:00 2001
|
|
From: Daniel Badea <daniel.badea@windriver.com>
|
|
Date: Thu, 23 Mar 2017 08:04:31 +0000
|
|
Subject: [PATCH] ceph jewel rebase
|
|
|
|
---
|
|
manifests/mon.pp | 1 +
|
|
manifests/rgw.pp | 33 +++++++++++++++++++++++++--------
|
|
manifests/rgw/keystone.pp | 6 +++---
|
|
3 files changed, 29 insertions(+), 11 deletions(-)
|
|
|
|
diff --git a/manifests/mon.pp b/manifests/mon.pp
|
|
index b3458d6..17cb925 100644
|
|
--- a/manifests/mon.pp
|
|
+++ b/manifests/mon.pp
|
|
@@ -106,6 +106,7 @@ define ceph::mon (
|
|
start => "service ceph start mon.${id}",
|
|
stop => "service ceph stop mon.${id}",
|
|
status => "service ceph status mon.${id}",
|
|
+ enable => $mon_enable,
|
|
}
|
|
}
|
|
|
|
diff --git a/manifests/rgw.pp b/manifests/rgw.pp
|
|
index ebc83ce..56fb4a8 100644
|
|
--- a/manifests/rgw.pp
|
|
+++ b/manifests/rgw.pp
|
|
@@ -193,23 +193,40 @@ define ceph::rgw (
|
|
status => "systemctl status ceph-radosgw",
|
|
}
|
|
} else {
|
|
+ if $rgw_enable {
|
|
+ file { "${rgw_data}/sysvinit":
|
|
+ ensure => present,
|
|
+ before => Service["radosgw-${name}"],
|
|
+ }
|
|
+ }
|
|
+
|
|
Service {
|
|
- name => "ceph-radosgw@${name}",
|
|
- enable => $rgw_enable,
|
|
+ name => "radosgw-${name}",
|
|
+ start => 'service radosgw start',
|
|
+ stop => 'service radosgw stop',
|
|
+ status => 'service radosgw status',
|
|
+ provider => $::ceph::params::service_provider,
|
|
}
|
|
}
|
|
|
|
- service { $rgw_service:
|
|
+ #for RHEL/CentOS7, systemctl needs to reload to pickup the ceph-radosgw init file
|
|
+ if (($::operatingsystem == 'RedHat' or $::operatingsystem == 'CentOS') and (versioncmp($::operatingsystemmajrelease, '7') >= 0))
|
|
+ {
|
|
+ exec { 'systemctl-reload-from-rgw': #needed for the new init file
|
|
+ command => '/usr/bin/systemctl daemon-reload',
|
|
+ }
|
|
+ }
|
|
+ service { "radosgw-${name}":
|
|
ensure => $rgw_ensure,
|
|
- tag => ['ceph-radosgw']
|
|
+ tag => ['radosgw']
|
|
}
|
|
|
|
- Ceph_config<||> ~> Service<| tag == 'ceph-radosgw' |>
|
|
+ Ceph_config<||> -> Service["radosgw-${name}"]
|
|
Package<| tag == 'ceph' |> -> File['/var/lib/ceph/radosgw']
|
|
Package<| tag == 'ceph' |> -> File[$log_file]
|
|
File['/var/lib/ceph/radosgw']
|
|
-> File[$rgw_data]
|
|
- -> Service<| tag == 'ceph-radosgw' |>
|
|
- File[$log_file] -> Service<| tag == 'ceph-radosgw' |>
|
|
- Ceph::Pool<||> -> Service<| tag == 'ceph-radosgw' |>
|
|
+ -> Service["radosgw-${name}"]
|
|
+ File[$log_file] -> Service["radosgw-${name}"]
|
|
+ Ceph::Pool<||> -> Service["radosgw-${name}"]
|
|
}
|
|
diff --git a/manifests/rgw/keystone.pp b/manifests/rgw/keystone.pp
|
|
index 8351177..c371fd0 100644
|
|
--- a/manifests/rgw/keystone.pp
|
|
+++ b/manifests/rgw/keystone.pp
|
|
@@ -148,7 +148,7 @@ define ceph::rgw::keystone (
|
|
exec { "${name}-nssdb-ca":
|
|
command => "/bin/true # comment to satisfy puppet syntax requirements
|
|
set -ex
|
|
-wget --no-check-certificate ${rgw_keystone_url}/v2.0/certificates/ca -O - |
|
|
+wget --no-check-certificate ${rgw_keystone_url}/${rgw_keystone_version}/certificates/ca -O - |
|
|
openssl x509 -pubkey | certutil -A -d ${nss_db_path} -n ca -t \"TCu,Cu,Tuw\"
|
|
",
|
|
unless => "/bin/true # comment to satisfy puppet syntax requirements
|
|
@@ -161,7 +161,7 @@ certutil -d ${nss_db_path} -L | grep ^ca
|
|
exec { "${name}-nssdb-signing":
|
|
command => "/bin/true # comment to satisfy puppet syntax requirements
|
|
set -ex
|
|
-wget --no-check-certificate ${rgw_keystone_url}/v2.0/certificates/signing -O - |
|
|
+wget --no-check-certificate ${rgw_keystone_url}/${rgw_keystone_version}/certificates/signing -O - |
|
|
openssl x509 -pubkey | certutil -A -d ${nss_db_path} -n signing_cert -t \"P,P,P\"
|
|
",
|
|
unless => "/bin/true # comment to satisfy puppet syntax requirements
|
|
@@ -176,7 +176,7 @@ certutil -d ${nss_db_path} -L | grep ^signing_cert
|
|
-> File[$nss_db_path]
|
|
-> Exec["${name}-nssdb-ca"]
|
|
-> Exec["${name}-nssdb-signing"]
|
|
- ~> Service<| tag == 'ceph-radosgw' |>
|
|
+ ~> Service<| tag == 'radosgw' |>
|
|
} else {
|
|
ceph_config {
|
|
"client.${name}/nss_db_path": ensure => absent;
|
|
--
|
|
2.7.4
|
|
|