Skip to content
This repository has been archived by the owner on Mar 1, 2023. It is now read-only.

G-Core/terraform-provider-gcorelabs

Repository files navigation

DEPRECATED

Terraform G-Core Labs Provider

G-Core Labs

====================================================================================

Requirements

  • Terraform 0.13.x
  • Go 1.14 (to build the provider plugin)

Building the provider

$ mkdir -p $GOPATH/src/github.com/terraform-providers
$ cd $GOPATH/src/github.com/terraform-providers
$ git clone https://github.com/G-Core/terraform-provider-gcorelabs.git
$ cd $GOPATH/src/github.com/terraform-providers/terraform-provider-gcorelabs
$ make build

Override Terraform provider

To override terraform provider for development goals you do next steps:

create Terraform configuration file

$ touch ~/.terraformrc

point provider to development path

provider_installation { 
 
  dev_overrides { 
      "local.gcorelabs.com/repo/gcore" = "/<dev-path>/terraform-provider-gcorelabs/bin" 
  } 
 
  # For all other providers, install them directly from their origin provider 
  # registries as normal. If you omit this, Terraform will _only_ use 
  # the dev_overrides block, and so no other providers will be available. 
  direct {} 
}

add local.gcorelabs.com/repo/gcore to .tf configuration file

terraform {
  required_version = ">= 0.13.0"

  required_providers {
    gcore = {
      source = "local.gcorelabs.com/repo/gcore"
    }
  }
}

Using the provider

To use the provider, prepare configuration files based on examples

$ cp ./examples/... .
$ terraform init

Thank You