open-consul/test/load/packer
s-christoff 8fc4de0ead
docs: Update load test documentation and minor clean ups (#9548)
2021-01-15 12:41:06 -06:00
..
consul-ami docs: Update load test documentation and minor clean ups (#9548) 2021-01-15 12:41:06 -06:00
loadtest-ami docs: Update load test documentation and minor clean ups (#9548) 2021-01-15 12:41:06 -06:00
.gitignore docs: Update load test documentation and minor clean ups (#9548) 2021-01-15 12:41:06 -06:00
README.md docs: Update load test documentation and minor clean ups (#9548) 2021-01-15 12:41:06 -06:00

README.md

Terraform Consul Load Testing

Packer will output AMI IDs when it completes - save these AMI IDs as Terraform will require them later.

==> Builds finished. The artifacts of successful builds are:
--> amazon-ebs: AMIs were created:

us-east-1: ami-19601070

Consul AMI:

Within the consul-ami/ directory

  1. Retrieve your Datadog API key, set this as an environment variable, ex: export DD_API_KEY=$YOURDDAPIKEYHERE
  2. Set the AWS_DEFAULT_REGION for Packer, ex: export AWS_DEFAULT_REGION=us-east-1
  3. Run packer build consul.json.

For additional customization you can add tags within the scripts/datadog.yaml file. An example of a tag could be "consul_version" : "consulent_175". These tags are searchable through the datadog dashboard. Another form of customization is changing the datacenter tag within scripts/telemetry.json, however it is defaulted to us-east-1.

Load Test AMI

Within the loadtest-ami/ directory

  1. Set the AWS_DEFAULT_REGION for Packer, ex: export AWS_DEFAULT_REGION=us-east-1
  2. Run the command packer build loadtest.json

The script that k6 runs is found within scripts/loadtest.js. This script can be updated to send requests to more Consul endpoints. For additional information on k6 please check out their guides.