Skip to content

Commit

Permalink
pre release changes
Browse files Browse the repository at this point in the history
  • Loading branch information
witalisoft committed Mar 21, 2024
1 parent 0986006 commit 8f37ce2
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 24 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,11 @@ jobs:
run: |
git diff --compact-summary --exit-code || \
(echo; echo "Unexpected difference in directories after code generation. Run 'go generate ./...' command and commit."; exit 1)
- name: Check generated docs
run: |
go install "github.com/hashicorp/terraform-plugin-docs/cmd/tfplugindocs"
make docs
git diff --exit-code
# Run acceptance tests in a matrix with Terraform CLI versions
test:
Expand Down
6 changes: 6 additions & 0 deletions GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,9 @@ testacc:
.PHONY: local-build
local-build:
go install .

# Generate docs
.PHONY: docs
docs:
@which tfplugindocs &>/dev/null || (echo "install tfplugindocs (https://github.com/hashicorp/terraform-plugin-docs)"; exit 1)
tfplugindocs generate .
36 changes: 16 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,40 +4,36 @@ This is the [Terraform](https://www.terraform.io/) provider for the [Netdata Clo

This provider allows you to install and manage Netdata Cloud resources using Terraform.


## Contents

* [Requirements](#requirements)
* [Getting Started](#getting-started)

## Requirements

- [Terraform](https://www.terraform.io/downloads.html) v1.1.0 or later
- [Go](https://golang.org/doc/install) v1.20 or later (to build the provider plugin)
* [Terraform](https://www.terraform.io/downloads.html) v1.1.0 or later
* [Go](https://golang.org/doc/install) v1.20 or later (to build the provider plugin)

## Getting Started

* from terraform registry

TODO

* from source code

* setup your [CLI configuration](https://developer.hashicorp.com/terraform/cli/config/config-file#development-overrides-for-provider-developers)
* setup your [CLI configuration](https://developer.hashicorp.com/terraform/cli/config/config-file#development-overrides-for-provider-developers)

```console
$ cat ~/.terraformrc
provider_installation {
dev_overrides {
# TODO: Update this string with the published name of your provider
"netdata.cloud/todo/netdata" = "<your GOBIN directory>"
}
direct {}
}
```
```console
$ cat ~/.terraformrc
provider_installation {
dev_overrides {
"netdata/netdata" = "<your GOBIN directory>"
}
direct {}
}
```

* build the provider
* build the provider

```console
$ make local-build
```
```console
$ make local-build
```
3 changes: 1 addition & 2 deletions examples/complete/main.tf
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
terraform {
required_providers {
netdata = {
# TODO: Update this string with the published name of your provider.
source = "netdata.cloud/todo/netdata"
source = "netdata/netdata"
}
}
required_version = ">= 1.1.0"
Expand Down
3 changes: 1 addition & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ func main() {
flag.Parse()

opts := providerserver.ServeOpts{
// TODO: Update this string with the published name of your provider.
Address: "netdata.cloud/todo/netdata",
Address: "registry.terraform.io/netdata/netdata",
Debug: debug,
}

Expand Down

0 comments on commit 8f37ce2

Please sign in to comment.