anchor.diff:      hostPath:
         path: /var/lib/docker/containers
   ----
  -
  -This will start a pod on the node & post the container logs to Elasticsearch.
  -
  -## Validate
  -
  -To validate it is working, we will query Elasticsearch & check that the data is
  -correctly being persisted. First, we need to identify one of the Elasticsearch
  -pods:
  -
  -[source,bash]
  -----
  -oc get pods -l component=elasticsearch
  -----
  -
  -And then we can query Elasticsearch, replacing the pod ID with one returned
  -from the above call:
  -
  -[source,bash]
  -----
  -oc exec -p <podID> -c elasticsearch -- curl -s localhost:9200/_cat/indices?v
  +====
  +
  +This starts a pod on the node and posts the container logs to *Elasticsearch*.
  +
  +To validate it is working, you can query *Elasticsearch* and check that the data
  +is correctly being persisted. First, identify one of the *Elasticsearch* pods:
  +
  +----
  +$ oc get pods -l component=elasticsearch
  +----
  +
  +Then query *Elasticsearch*, replacing the pod ID with one returned from the
  +above command:
  +
  +----
  +$ oc exec -p <pod_id> -c elasticsearch -- curl -s localhost:9200/_cat/indices?v
   ----
   
   You should see output similar to the following:
   
  -```
  +====
  +----
   health status index               pri rep docs.count docs.deleted store.size pri.store.size
   yellow open   logstash-2015.06.05   5   1        540            0      251kb          251kb
  -```
  -
  -If the value for `docs.count` is more than 0, then log records are being sent
  -to Elasticsearch & you're all set.
  -
  -== Creating Kibana service
  -
  -To create the Kibana service save the following spec to your filesystem:
  -
  -[souce,yaml]
  +----
  +====
  +
  +If the value for `docs.count` is more than 0, then log records are being
  +correctly sent to *Elasticsearch*.
  +
  +=== Creating the Kibana Service
  +
  +To create the *Kibana* service, save the following specification to your file
  +system:
  +
  +====
  +
  +[source,yaml]
   ----
   apiVersion: "v1"
   kind: "List"
  
positive.code:         utc
      </match>
  ----
  
  *Enabling fluentd*
  
  [shell,sh]
  ****
      # systemctl enable td-agent
      # systemctl start td-agent
  ****
  
  TIP: Any errors will be logged in the *_/var/log/td-agent/td-agent.log_* file.
  
  You should now find all the containers' logs available on the master in the
  *_/var/log/td-agent/containers.log_* file.
  
  ---
  
  = Using Elasticsearch
  
  https://www.elastic.co/products/elasticsearch[Elasticsearch] is an open source
  distributed document database that indexes documents & provides full-text
  search capabilities. By storing container logs in Elasticsearch, users will be
  able to search all content & filter appropriately. This documentation shows how
  to run https://www.elastic.co/products/kibana[Kibana].
  
  This option requires more configuration & more resources than the
  <<Using a Centralized Filesystem,centralised filesystem>> option, but makes logs more useful
  for troubleshooting & fault finding.
  
  Enabling aggregated logging to Elasticsearch involves:
  
  . <<Creating an Elasticsearch cluster>>
  . <<Creating logging pods>>
  . <<Creating Kibana service>>
  
  == Creating an Elasticsearch cluster
  
  Logs are stored in an Elasticsearch cluster running on OpenShift. This cluster
  is scalable via a replication controller so you can scale the Elasticsearch
  cluster up & down as required.
  
  The following is the manifest for the Elasticsearch cluster:
  
  [source,yaml]
  ----
  
negative.code:   path: openshift.local.manifests
    fileCheckIntervalSeconds: 10
  ----
  ====
  
  To create the logging pod, create a file with the following contents in the
  directory specified by `*podManifestConfig.path*` above:
  
  ====
  
  [source,yaml]
  ----
  