diff --git a/modules/monitoring-creating-cluster-monitoring-configmap.adoc b/modules/monitoring-creating-cluster-monitoring-configmap.adoc index be0a035a43..f8acd9d034 100644 --- a/modules/monitoring-creating-cluster-monitoring-configmap.adoc +++ b/modules/monitoring-creating-cluster-monitoring-configmap.adoc @@ -3,36 +3,26 @@ // * monitoring/cluster_monitoring/configuring-the-monitoring-stack.adoc [id="creating-cluster-monitoring-configmap_{context}"] -= Creating cluster monitoring ConfigMap += Creating a cluster monitoring ConfigMap -To configure the Prometheus Cluster Monitoring stack, you must create the cluster monitoring ConfigMap. +To configure the {product-title} monitoring stack, you must create the cluster monitoring ConfigMap. .Prerequisites -* An installed `oc` CLI tool -* Administrative privileges for the cluster +* You have access to the cluster as a user with the cluster-admin role. +* You have installed the OpenShift CLI (`oc`). .Procedure . Check whether the `cluster-monitoring-config` ConfigMap object exists: + +[source,terminal] ---- $ oc -n openshift-monitoring get configmap cluster-monitoring-config ---- -. If it does not exist, create it: -+ ----- -$ oc -n openshift-monitoring create configmap cluster-monitoring-config ----- - -. Start editing the `cluster-monitoring-config` ConfigMap: -+ ----- -$ oc -n openshift-monitoring edit configmap cluster-monitoring-config ----- - -. Create the `data` section if it does not exist yet: +. If the ConfigMap does not exist: +.. Create the following YAML manifest. In this example the file is called `cluster-monitoring-config.yaml`: + [source,yaml] ---- @@ -44,3 +34,10 @@ metadata: data: config.yaml: | ---- ++ +.. Apply the configuration to create the ConfigMap: ++ +[source,terminal] +---- +$ oc apply -f cluster-monitoring-config.yaml +----