summaryrefslogtreecommitdiffstats
path: root/lib/undercloud-functions.sh
diff options
context:
space:
mode:
authorDan Radez <dradez@redhat.com>2016-11-14 12:36:27 -0500
committerDan Radez <dradez@redhat.com>2016-11-17 17:08:46 -0500
commite36f790d036c0bfb5d7ed81d656f9bb1f5200a1a (patch)
tree94577d399e68c0d2e6580c007c47e4303913ee63 /lib/undercloud-functions.sh
parent122e9d68ebd38e6e2ff82548fb77812a04c05e17 (diff)
Allow passing a device name to ceph
JIRA: APEX-347 Change-Id: Ibc6d141e20faf613e0f6314286b55aff01ce862e Signed-off-by: Dan Radez <dradez@redhat.com>
Diffstat (limited to 'lib/undercloud-functions.sh')
-rwxr-xr-xlib/undercloud-functions.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/undercloud-functions.sh b/lib/undercloud-functions.sh
index d3beb60c..bd93aa78 100755
--- a/lib/undercloud-functions.sh
+++ b/lib/undercloud-functions.sh
@@ -207,6 +207,10 @@ openstack-config --set undercloud.conf DEFAULT undercloud_hostname "undercloud.$
sudo openstack-config --set /etc/ironic/ironic.conf disk_utils iscsi_verify_attempts 30
sudo openstack-config --set /etc/ironic/ironic.conf disk_partitioner check_device_max_retries 40
+if [[ -n "${deploy_options_array['ceph_device']}" ]]; then
+ sed -i '/ExtraConfig/a\\ ceph::profile::params::osds: {\\x27${deploy_options_array['ceph_device']}\\x27: {}}' opnfv-environment.yaml
+fi
+
sudo sed -i '/CephClusterFSID:/c\\ CephClusterFSID: \\x27$(cat /proc/sys/kernel/random/uuid)\\x27' /usr/share/openstack-tripleo-heat-templates/environments/storage-environment.yaml
sudo sed -i '/CephMonKey:/c\\ CephMonKey: \\x27'"\$(ceph-authtool --gen-print-key)"'\\x27' /usr/share/openstack-tripleo-heat-templates/environments/storage-environment.yaml
sudo sed -i '/CephAdminKey:/c\\ CephAdminKey: \\x27'"\$(ceph-authtool --gen-print-key)"'\\x27' /usr/share/openstack-tripleo-heat-templates/environments/storage-environment.yaml