Skip to content

Instantly share code, notes, and snippets.

@bmorelli25
Created April 1, 2019 19:28
Show Gist options
  • Save bmorelli25/4ccf9d28b8c5edbf0212ee3920f22d9d to your computer and use it in GitHub Desktop.
Save bmorelli25/4ccf9d28b8c5edbf0212ee3920f22d9d to your computer and use it in GitHub Desktop.
run-heartbeat-7.0.0-rc1
  1. Download https://staging.elastic.co/7.0.0-rc1-edbb4077/downloads/beats/heartbeat/heartbeat-7.0.0-rc1-darwin-x86_64.tar.gz and move it to a place where it will spark joy.
  2. tar xofp heartbeat-7.0.0-rc1-darwin-x86_64.tar.gz
  3. Overwrite your ~/heartbeat.yml with the following:
heartbeat.config.monitors:
  path: ${path.config}/monitors.d/*.yml
  reload.enabled: true
  reload.period: 1s

setup.template.settings:
  index.number_of_shards: 1
  index.codec: best_compression

output.elasticsearch:
  # Array of hosts to connect to.
  hosts: ["localhost:9200"]
  1. In the directory ~/monitors.d create any file that conforms to *.yml, and in it paste the following:
- type: tcp
  schedule: '@every 5s'
  hosts: ['tcp://localhost:9200/']
- type: http
  schedule: '@every 1s'
  urls: ['http://localhost:12349/']
  name: 'my-new-test-site-name'
- type: http
  schedule: '@every 10s'
  urls: ['https://www.elastic.co/']
  name: 'elastic-website'

From there you can run ./heartbeat and navigate to the heartbeat UI in Kibana. It needs to run against a 7.0 Kibana, so I’d recommend either checking out and running the 7.0 branch or downloading the version in staging.

When you’ve got everything running, you can modify what you’ve pasted in your monitors.d folder with custom urls and names.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment