No description
  • Go 95.6%
  • Shell 1.6%
  • Makefile 1.4%
  • HTML 1.4%
Find a file
2020-08-25 10:55:41 +02:00
.github Make CoC and support channels more visible 2017-11-01 23:04:38 +01:00
cloudscale Add support for global floating ips. 2020-08-24 13:55:26 +02:00
examples ED25519 is considered to be safer than NIST P-256 2017-08-21 18:52:39 +02:00
scripts Migrating to the Terraform Plugin SDK. 2019-12-16 14:46:43 +00:00
vendor Update to latest cloudscale-go-sdk. 2020-07-21 09:59:08 +02:00
website Add support for global floating ips. 2020-08-24 13:55:26 +02:00
.go-version correct goversion used to generate modules 2019-05-01 13:43:22 -04:00
.travis.yml deps: use go modules for dep mgmt 2019-05-01 13:38:34 -04:00
CHANGELOG.md Cleanup after v2.2.0 release 2020-07-23 17:17:39 +00:00
GNUmakefile Add 'make sweep'. 2020-07-23 18:18:23 +02:00
go.mod Update to latest cloudscale-go-sdk. 2020-07-21 09:59:08 +02:00
go.sum Update to latest cloudscale-go-sdk. 2020-07-21 09:59:08 +02:00
main.go Migrating to the Terraform Plugin SDK. 2019-12-16 14:46:43 +00:00
README.md Some more hints in README.md. 2020-04-07 10:29:26 +02:00

Terraform Provider

Requirements

  • Terraform 0.10.x
  • Go 1.11 (to build the provider plugin)

Building The Provider

Clone repository to: $GOPATH/src/github.com/terraform-providers/terraform-provider-cloudscale

$ mkdir -p $GOPATH/src/github.com/terraform-providers; cd $GOPATH/src/github.com/terraform-providers
$ git clone git@github.com:terraform-providers/terraform-provider-cloudscale

Enter the provider directory and build the provider

$ cd $GOPATH/src/github.com/terraform-providers/terraform-provider-cloudscale
$ make build

Using the provider

  1. Download and install Terraform
  2. Move terraform-provider-cloudscale executable to the root folder where main.tf is.
  $ mv terraform-provider-cloudscale /path/to/main.tf/folder
  1. Execute terraform plan
  2. terraform init

Developing the Provider

If you wish to work on the provider, you'll first need Go installed on your machine (version 1.11+ is required). You'll also need to correctly setup a GOPATH, as well as adding $GOPATH/bin to your $PATH.

To compile the provider, run make build. This will build the provider and put the provider binary in the $GOPATH/bin directory.

$ make build
...
$ $GOPATH/bin/terraform-provider-cloudscale
...

In order to test the provider, you can simply run make test.

$ make test

In order to run the full suite of Acceptance tests, run make testacc.

Note: Acceptance tests create real resources, and often cost money to run.

$ make testacc

In order to run run a subset of the tests:

$ TESTARGS="-run TestAccCloudscaleSubnet" make testacc

In order to upgrade the cloudscale-go-sdk.

go get -u github.com/cloudscale-ch/cloudscale-go-sdk
go mod vendor