Merge "[ceph-client] Add the ability to run Ceph commands from values"
This commit is contained in:
@@ -15,6 +15,6 @@ apiVersion: v1
|
|||||||
appVersion: v1.0.0
|
appVersion: v1.0.0
|
||||||
description: OpenStack-Helm Ceph Client
|
description: OpenStack-Helm Ceph Client
|
||||||
name: ceph-client
|
name: ceph-client
|
||||||
version: 0.1.35
|
version: 0.1.36
|
||||||
home: https://github.com/ceph/ceph-client
|
home: https://github.com/ceph/ceph-client
|
||||||
...
|
...
|
||||||
|
@@ -175,7 +175,7 @@ function disable_autoscaling () {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function set_cluster_flags () {
|
function set_cluster_flags () {
|
||||||
if [[ ! -z "${CLUSTER_SET_FLAGS}" ]]; then
|
if [[ -n "${CLUSTER_SET_FLAGS}" ]]; then
|
||||||
for flag in ${CLUSTER_SET_FLAGS}; do
|
for flag in ${CLUSTER_SET_FLAGS}; do
|
||||||
ceph osd set ${flag}
|
ceph osd set ${flag}
|
||||||
done
|
done
|
||||||
@@ -183,13 +183,19 @@ function set_cluster_flags () {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function unset_cluster_flags () {
|
function unset_cluster_flags () {
|
||||||
if [[ ! -z "${CLUSTER_UNSET_FLAGS}" ]]; then
|
if [[ -n "${CLUSTER_UNSET_FLAGS}" ]]; then
|
||||||
for flag in ${CLUSTER_UNSET_FLAGS}; do
|
for flag in ${CLUSTER_UNSET_FLAGS}; do
|
||||||
ceph osd unset ${flag}
|
ceph osd unset ${flag}
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function run_cluster_commands () {
|
||||||
|
{{- range .Values.conf.features.cluster_commands }}
|
||||||
|
ceph --cluster "${CLUSTER}" {{ . }}
|
||||||
|
{{- end }}
|
||||||
|
}
|
||||||
|
|
||||||
# Helper function to set pool properties only if the target value differs from
|
# Helper function to set pool properties only if the target value differs from
|
||||||
# the current value to optimize performance
|
# the current value to optimize performance
|
||||||
function set_pool_property() {
|
function set_pool_property() {
|
||||||
@@ -328,6 +334,7 @@ function convert_to_bytes() {
|
|||||||
|
|
||||||
set_cluster_flags
|
set_cluster_flags
|
||||||
unset_cluster_flags
|
unset_cluster_flags
|
||||||
|
run_cluster_commands
|
||||||
reweight_osds
|
reweight_osds
|
||||||
|
|
||||||
{{ $targetOSDCount := .Values.conf.pool.target.osd }}
|
{{ $targetOSDCount := .Values.conf.pool.target.osd }}
|
||||||
|
@@ -229,6 +229,10 @@ conf:
|
|||||||
# List of flags to set or unset separated by spaces
|
# List of flags to set or unset separated by spaces
|
||||||
set: ""
|
set: ""
|
||||||
unset: ""
|
unset: ""
|
||||||
|
cluster_commands:
|
||||||
|
# Add additional commands to run against the Ceph cluster here
|
||||||
|
- osd require-osd-release octopus
|
||||||
|
- status
|
||||||
pool:
|
pool:
|
||||||
# NOTE(portdirect): this drives a simple approximation of
|
# NOTE(portdirect): this drives a simple approximation of
|
||||||
# https://ceph.com/pgcalc/, the `target.osd` key should be set to match the
|
# https://ceph.com/pgcalc/, the `target.osd` key should be set to match the
|
||||||
|
@@ -36,4 +36,5 @@ ceph-client:
|
|||||||
- 0.1.33 More robust naming of clusterrole-checkdns
|
- 0.1.33 More robust naming of clusterrole-checkdns
|
||||||
- 0.1.34 Migrated CronJob resource to batch/v1 API version
|
- 0.1.34 Migrated CronJob resource to batch/v1 API version
|
||||||
- 0.1.35 Handle multiple mon versions in the pool job
|
- 0.1.35 Handle multiple mon versions in the pool job
|
||||||
|
- 0.1.36 Add the ability to run Ceph commands from values
|
||||||
...
|
...
|
||||||
|
Reference in New Issue
Block a user