Skip to content

khaledyoussef24/terraform-provider-grid

Repository files navigation

Grid provider for terraform

  • A resource, and a data source (internal/provider/),
  • Examples (examples/)

Requirements

  • Terraform >= 0.13.x

  • Go >= 1.15

  • A registered twin on the grid with a funed account steps

  • Only if not using the rmb proxy (enabled by default): Redis running on localhost with port 6379 and yggdrasil

Building The Provider (for development only)

make
  • to use the built plugin in a terraform file, use the following provider config:
terraform {
  required_providers {
    grid = {
      source = "threefoldtech/grid"
    }
  }
}

Generating the docs

make docs

Using the provider

cd examples/resources/singlenode
export MNEMONICS="<mnemonics words>"
export NETWORK="<network>" # dev or test
terraform init && terraform apply -parallelism=1 # creates resources defined in main.tf
terraform destroy -parallelism=1 # destroy the created resource

Docs for resources and their arguments can be found here. For a thorough walkthrough over the usage and requirements of the plugin. please visit the wiki page.

Current limitation

Run tests

To run the tests, export MNEMONICS and NETWORK export MNEMONICS="" export NETWORK="" # dev or test run the following command

go test ./tests/... -p 1 --tags=integration

OR by using gotestsum

sudo apt -y install gotestsum

go install gotest.tools/gotestsum@latest

gotestsum ./tests/... -p 1 --tags=integration

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published