Code Monkey home page Code Monkey logo

docker-k6-grafana-influxdb's Introduction

docker-k6-grafana-influxdb

Demonstrates how to run load tests with containerised instances of K6, Grafana and InfluxDB.

Article

This is the accompanying source code for the following article. Please read for a detailed breakdown of the code and how K6, Grafana and InfluxDB work together using Docker Compose:

https://medium.com/swlh/beautiful-load-testing-with-k6-and-docker-compose-4454edb3a2e3

Dashboards

The dashboard in /dashboards is adapted from the excellent K6 / Grafana dashboard here: https://grafana.com/grafana/dashboards/2587

There are only two small modifications:

  • the data source is configured to use the docker created InfluxDB data source
  • the time period is set to now-15m, which I feel is a better view for most tests

Scripts

The script here is an example of a low Virtual User (VU) load test of the excellent Star Wars API: https://swapi.dev/

If you're tinkering with the script, it is just a friendly open source API, be gentle!

docker-k6-grafana-influxdb's People

Contributors

hosamalmoghraby avatar luketn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

docker-k6-grafana-influxdb's Issues

Error running the docker-compose run k6 run /scripts/ewoks.js

Hi @luketn how are your? I am writing you since i am having an error running the docker-compose run k6 run /scripts/ewoks.js

I have clone the repository and from docker-k6-grafana-influxdb folder after running the docker-compose up -d influxdb grafana (the container is running)
image1

But when i run the docker-compose run k6 run /scripts/ewoks.js I am getting the following error:
image2

Do you know what could be the root cause? i am running from mac

Thanks a lot isn advance!

Following instructions as-is leads to InfluxDb error

ERRO[0001] InfluxDB: Couldn't write stats  error="{\"code\":\"unauthorized\",\"message\":\"unauthorized access\"}"

I have tried this using WSL 2.0 on Windows 10, and directly on Windows 10 and get the same error. I have not managed to figure out the cause/fix yet.

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.