Thanks to visit codestin.com
Credit goes to github.com

Skip to content

MooyongLee/k6-example-aws-codebuild

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Automated k6 load testing with AWS CodeBuild CI/CD

This is an example repo for how to setup k6 with AWS CodeBuild CI/CD to build load testing into an automation flow.

The full guide describing how to use this repository is located here.

Examples

File Description
local-example/buildspec.yml Runs locally on AWS infrastructure
cloud-example/buildspec.yml Runs on k6 cloud

Run Local

# Run locally
k6 run scripts/test.js

# Run via Docker
docker run -i loadimpact/k6 run - <scripts/test.js

Run Cloud

# Run directly
k6 login cloud --token <YOUR_K6_CLOUD_API_TOKEN>
k6 cloud scripts/cloud-test.js

# Run via Docker
docker run -i -e K6_CLOUD_TOKEN=<API_TOKEN> loadimpact/k6 cloud - <scripts/cloud-test.js

# Alternative Docker version with mounting option
docker run -i -e K6_CLOUD_TOKEN=<API_TOKEN> -v "$PWD/scripts:/cloud-test.js" loadimpact/k6 cloud /cloud-test.js

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • JavaScript 100.0%