Browse the Repo

file-type-icon.circleci
file-type-icon_docs
file-type-iconexamples
file-type-iconchronograf-ami
file-type-iconinfluxdb-ami
file-type-iconinfluxdb-cluster-simple
file-type-iconlocal-test
file-type-iconuser-data
file-type-iconREADME.md
file-type-iconkapacitor-ami
file-type-iconlocal-mocks
file-type-icontelegraf-ami
file-type-icontick-ami
file-type-icontick-multi-cluster
file-type-icontick-single-cluster
file-type-iconmodules
file-type-icontest
file-type-icon.gitignore
file-type-icon.pre-commit-config.yaml
file-type-iconCODEOWNERS
file-type-iconCONTRIBUTING.md
file-type-iconLICENSE
file-type-iconNOTICE
file-type-iconREADME.md
file-type-iconmain.tf
file-type-iconoutputs.tf
file-type-iconvariables.tf

Browse the Repo

file-type-icon.circleci
file-type-icon_docs
file-type-iconexamples
file-type-iconchronograf-ami
file-type-iconinfluxdb-ami
file-type-iconinfluxdb-cluster-simple
file-type-iconlocal-test
file-type-iconuser-data
file-type-iconREADME.md
file-type-iconkapacitor-ami
file-type-iconlocal-mocks
file-type-icontelegraf-ami
file-type-icontick-ami
file-type-icontick-multi-cluster
file-type-icontick-single-cluster
file-type-iconmodules
file-type-icontest
file-type-icon.gitignore
file-type-icon.pre-commit-config.yaml
file-type-iconCODEOWNERS
file-type-iconCONTRIBUTING.md
file-type-iconLICENSE
file-type-iconNOTICE
file-type-iconREADME.md
file-type-iconmain.tf
file-type-iconoutputs.tf
file-type-iconvariables.tf
InfluxDB

InfluxDB

Deploy an InfluxDB cluster. Supports automatic bootstrapping and auto healing.

Code Preview

Preview the Code

mobile file icon

README.md

down

InfluxDB Single Cluster Example

The root folder of this repo shows an example of Terraform code that uses the influxdb-cluster module to deploy a InfluxDB Enterprise cluster in AWS. The cluster consists of one Auto Scaling Group (ASG) that runs InfluxDB:

InfluxDB single-cluster architecture

This example also deploys a Load Balancer in front of the InfluxDB cluster using the load-balancer module.

You will need to create an Amazon Machine Image (AMI) that has InfluxDB installed, which you can do using the influxdb-ami example).

To see an example of InfluxDB deployed across separate clusters, see the tick-multi-cluster example. For more info on how the InfluxDB cluster works, check out the influxdb-cluster documentation.

Quick start

To deploy a InfluxDB Cluster:

  1. git clone this repo to your computer.
  2. Optional: build a custom InfluxDB AMI. See the influxdb-ami example documentation for instructions. Make sure to note down the ID of the AMI.
  3. Install Terraform.
  4. Open the variables.tf file in the root of this repo, set the environment variables specified at the top of the file, and fill in any other variables that don't have a default. If you built a custom AMI, put its ID into the ami_id variable. If you didn't, this example will use public AMIs that Gruntwork has published, which are fine for testing/learning, but not recommended for production use.
  5. Run terraform init in the root folder of this repo.
  6. Run terraform apply in the root folder of this repo.

Connecting to the cluster

Check out How do you connect to the InfluxDB cluster documentation.

Questions? Ask away.

We're here to talk about our services, answer any questions, give advice, or just to chat.

Ready to hand off the Gruntwork?