Canarytrace in Kubernetes
#
What you’ll learn
- You will know how to run Canarytrace on cloud
- You will know how to setup Elasticsearch cloud
- You will know how to start Kubernetes on DigitalOcean
- You will be know how to prepare the cronjob for deploy and rotate Canarytrace Smoke
- Basic of working with the Lens application
#
Canarytrace on cloudThis tutorial introduces you to the essentials of Canarytrace community edition by walking you through run first smoke in Kubernetes on cloud.
#
Step-by-stepWe will go step by step to build your Canarytrace infrastructure based on Kubernetes and Elasticsearch in cloud.
- Create deployment (Elasticsearch and Kibana) on https://www.elastic.co/
- Create Kubernetes cluster on https://www.digitalocean.com/
- Setup Elasticsearch and Kibana via Canarytrace Installer
- Prepare and deploy Canarytace to Kubernetes
#
Create deployment on Elastic cloud- Create account on https://cloud.elastic.co/registration
- Create Elasticsearch and Kibana deployment, see below on screencast
- save your Elasticsearch endpoint e.g.
https://9e0f4b1db5234c48b0933bd421b543f0.us-central1.gcp.cloud.es.io:9243
- save your Kibana endpoint e.g.
https://2036be9b05634936879e34555dbaa17b.us-central1.gcp.cloud.es.io:9243
- save your credentials e.g. username:
elastic
and password:GnkOwVswOkGqHRKuXzCBbwUE
#
Create Kubernetes cluster on DigitalOcean- Create account on https://cloud.digitalocean.com/registrations/new
- Create Kubernetes cluster, see below on screencast
- Download config
Action > Download Config
into download directorycanarytrace-kubeconfig.yaml
#
Setup Elasticsearch and Kibana- For setup use our Canarytrace Installer in a docker compose
- save the code to a file
docker-compose.yaml
and rundocker-compose up
Installer result
#
Prepare deployment script / CronJobOpen Cronjob in your editor and edit labels in env
:
BASE_URL
add your landing pages separated by semicolonELASTIC_CLUSTER
add your Elasticsearch endpointELASTIC_HTTP_AUTH
add your Elasticsearch credentials in a formatusername:password
CronJob with Canarytrace smoke
#
Lens | The Kubernetes IDELens is open-source and multi-platform IDE for controll Kubernetes cluster.
Last steps for run Canarytrace Smoke in Kubernetes
- Download and install Lens. Please select correct platform (Linux, MacOS or Windows)
- Drag and drop your
canarytrace-kubeconfig.yaml
file to Lens and use it to add your Kubernetes cluster. See below on screencast. - Copy your
CronJob
with Canarytrace for create resource and deploy to Kubernetes. See below on screencast.
#
View the result in KibanaThat's all 🎉 Now wait a few minutes and you can explore dashboard and visualizations in Kibana. Open your Kibana endpoint https://2036be9b05634936879e34555dbaa17b.us-central1.gcp.cloud.es.io:9243
in your browser and navigate to Dashboard / Canarytrace Smoke Overview
- Do you find mistake or have any questions? Please create issue, thanks 👍
- Have more questions? Contact us.