Giter VIP home page Giter VIP logo

monitoring-the-easy-way's Introduction

monitoring-the-easy-way

This repository includes all the content needed to make the workshop of the same name, the main goal is to have a working environment to learn an practices monitoring concepts.

The tools needed to deploy and use this repository on the next list:

Setup local environment

Configure Docker Desktop

All the workshop is based on the usage of Docker containers and for explaining better the concepts we will use Kuberentes, in order to not needing an online deployment on a cloud provider, we need to activate the Kubernetes feature included on Docker Desktop.

First, you have to install Docker Desktop following the documentation

You only need to access the Docker preferences and navigate to the Kubernetes section to activate. It will take some minutes to be ready depending on your computer and internet bandwidth.

Configure Helm

When the local Kubernetes context is ready you can start with the Helm configuration to have your environment ready.

At the moment of preparing this workshop, the current Helm version is 3 and because of that, all the steps are based on that specific version.

To install Helm as a local command you should follow the quickstart documentation and add at least one repository to start installing charts.

helm repo add stable https://charts.helm.sh/stable

Extra repositories

AS a more complete environment 4 more repositories can be added to have acces to more charts:

helm repo add kiwigrid https://kiwigrid.github.io
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus-comunity https://prometheus-community.github.io/helm-charts
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx

Don't forget to update your repository list

helm repo update

# Install ingress controller

To make the access more ease we have prepared a basic ingress-controller using the comunity version of Nginx ingress controller, you can install it localy using next command:

helm install proxy proxy

Installing the tools

First we need to create a namespace.

kubectl create monitoring-easy

And set the new namespaces the current context.

kubectl config set-context --current --namespace=monitoring-easy

In order to install the tools needed you can simply run next commend to install the chart that aready includes Grafana and Prometheus as dependencies and will leave the cluster ready to start colecting and showing data.

cd monitoring-stack
helm dependency update
helm install monitoring-stack .

You can now see how the diferent services are created and starts creating the pods needed. When all services are on running state you can connect to your grafana for the first time and you need to run next commands to obtain the right port to connect and the random admin password generated during the installation process.

kubectl get secrets monitoring-stack-grafana -o jsonpath="{.data.admin-password}" | base64 --decode ; echo
export GRAFANA_PORT=$(kubectl get service -o jsonpath="{.spec.ports[0].nodePort}" monitoring-stack-grafana)
echo http://localhost:$GRAFANA_PORT

Install example service

This repository includes a basic server example that can be used to generate metrics and test the environment. You can install using next command:

helm install lab service-example

Install artillery

To demonstrate the different metris a benchmark tool is needed, one easy way to perform a load test is to use artillery you can install it by running next command:

sudo npm install -g artillery --allow-root --unsafe-perm=true

monitoring-the-easy-way's People

Contributors

wolmi avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.