Skip to content

Commit d42577b

Browse files
committed
🎉 setting up dbs datasource and db resource
1 parent adf96ee commit d42577b

15 files changed

+388
-604
lines changed

.github/CODEOWNERS

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
* @hashicorp/terraform-devex
1+
* @IvanOfThings

.vscode/settings.json

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"cSpell.words": [
3+
"tflog"
4+
]
5+
}

GNUmakefile

+36
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,42 @@
1+
TEST?=$$(go list ./... | grep -v 'vendor')
2+
HOSTNAME=hashicorp.com
3+
NAMESPACE=edu
4+
NAME=clickhouse
5+
BINARY=terraform-provider-${NAME}
6+
VERSION=0.2
7+
OS_ARCH=linux_amd64
8+
19
default: testacc
210

311
# Run acceptance tests
412
.PHONY: testacc
513
testacc:
614
TF_ACC=1 go test ./... -v $(TESTARGS) -timeout 120m
15+
16+
build:
17+
go build -o ${BINARY}
18+
19+
20+
release:
21+
GOOS=darwin GOARCH=amd64 go build -o ./bin/${BINARY}_${VERSION}_darwin_amd64
22+
GOOS=freebsd GOARCH=386 go build -o ./bin/${BINARY}_${VERSION}_freebsd_386
23+
GOOS=freebsd GOARCH=amd64 go build -o ./bin/${BINARY}_${VERSION}_freebsd_amd64
24+
GOOS=freebsd GOARCH=arm go build -o ./bin/${BINARY}_${VERSION}_freebsd_arm
25+
GOOS=linux GOARCH=386 go build -o ./bin/${BINARY}_${VERSION}_linux_386
26+
GOOS=linux GOARCH=amd64 go build -o ./bin/${BINARY}_${VERSION}_linux_amd64
27+
GOOS=linux GOARCH=arm go build -o ./bin/${BINARY}_${VERSION}_linux_arm
28+
GOOS=openbsd GOARCH=386 go build -o ./bin/${BINARY}_${VERSION}_openbsd_386
29+
GOOS=openbsd GOARCH=amd64 go build -o ./bin/${BINARY}_${VERSION}_openbsd_amd64
30+
GOOS=solaris GOARCH=amd64 go build -o ./bin/${BINARY}_${VERSION}_solaris_amd64
31+
GOOS=windows GOARCH=386 go build -o ./bin/${BINARY}_${VERSION}_windows_386
32+
GOOS=windows GOARCH=amd64 go build -o ./bin/${BINARY}_${VERSION}_windows_amd64
33+
34+
install: build
35+
mkdir -p ~/.terraform.d/plugins/${HOSTNAME}/${NAMESPACE}/${NAME}/${VERSION}/${OS_ARCH}
36+
mv ${BINARY} ~/.terraform.d/plugins/${HOSTNAME}/${NAMESPACE}/${NAME}/${VERSION}/${OS_ARCH}
37+
cp .env ~/.terraform.d/plugins/${HOSTNAME}/${NAMESPACE}/${NAME}/${VERSION}/${OS_ARCH}
38+
39+
40+
test:
41+
go test -i $(TEST) || exit 1
42+
echo $(TEST) | xargs -t -n4 go test $(TESTARGS) -timeout=30s -parallel=4

go.mod

+2-68
Original file line numberDiff line numberDiff line change
@@ -1,69 +1,3 @@
1-
module github.com/hashicorp/terraform-provider-scaffolding
1+
module terraform-provider-clickhouse
22

3-
go 1.18
4-
5-
require (
6-
github.com/hashicorp/terraform-plugin-docs v0.13.0
7-
github.com/hashicorp/terraform-plugin-log v0.7.0
8-
github.com/hashicorp/terraform-plugin-sdk/v2 v2.23.0
9-
)
10-
11-
require (
12-
github.com/Masterminds/goutils v1.1.1 // indirect
13-
github.com/Masterminds/semver/v3 v3.1.1 // indirect
14-
github.com/Masterminds/sprig/v3 v3.2.2 // indirect
15-
github.com/agext/levenshtein v1.2.2 // indirect
16-
github.com/apparentlymart/go-textseg/v13 v13.0.0 // indirect
17-
github.com/armon/go-radix v1.0.0 // indirect
18-
github.com/bgentry/speakeasy v0.1.0 // indirect
19-
github.com/davecgh/go-spew v1.1.1 // indirect
20-
github.com/fatih/color v1.13.0 // indirect
21-
github.com/golang/protobuf v1.5.2 // indirect
22-
github.com/google/go-cmp v0.5.9 // indirect
23-
github.com/google/uuid v1.3.0 // indirect
24-
github.com/hashicorp/errwrap v1.1.0 // indirect
25-
github.com/hashicorp/go-checkpoint v0.5.0 // indirect
26-
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
27-
github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 // indirect
28-
github.com/hashicorp/go-hclog v1.2.1 // indirect
29-
github.com/hashicorp/go-multierror v1.1.1 // indirect
30-
github.com/hashicorp/go-plugin v1.4.4 // indirect
31-
github.com/hashicorp/go-uuid v1.0.3 // indirect
32-
github.com/hashicorp/go-version v1.6.0 // indirect
33-
github.com/hashicorp/hc-install v0.4.0 // indirect
34-
github.com/hashicorp/hcl/v2 v2.14.0 // indirect
35-
github.com/hashicorp/logutils v1.0.0 // indirect
36-
github.com/hashicorp/terraform-exec v0.17.3 // indirect
37-
github.com/hashicorp/terraform-json v0.14.0 // indirect
38-
github.com/hashicorp/terraform-plugin-go v0.14.0 // indirect
39-
github.com/hashicorp/terraform-registry-address v0.0.0-20220623143253-7d51757b572c // indirect
40-
github.com/hashicorp/terraform-svchost v0.0.0-20200729002733-f050f53b9734 // indirect
41-
github.com/hashicorp/yamux v0.0.0-20181012175058-2f1d1f20f75d // indirect
42-
github.com/huandu/xstrings v1.3.2 // indirect
43-
github.com/imdario/mergo v0.3.13 // indirect
44-
github.com/mattn/go-colorable v0.1.12 // indirect
45-
github.com/mattn/go-isatty v0.0.14 // indirect
46-
github.com/mitchellh/cli v1.1.4 // indirect
47-
github.com/mitchellh/copystructure v1.2.0 // indirect
48-
github.com/mitchellh/go-testing-interface v1.14.1 // indirect
49-
github.com/mitchellh/go-wordwrap v1.0.0 // indirect
50-
github.com/mitchellh/mapstructure v1.5.0 // indirect
51-
github.com/mitchellh/reflectwalk v1.0.2 // indirect
52-
github.com/oklog/run v1.0.0 // indirect
53-
github.com/posener/complete v1.2.3 // indirect
54-
github.com/russross/blackfriday v1.6.0 // indirect
55-
github.com/shopspring/decimal v1.3.1 // indirect
56-
github.com/spf13/cast v1.5.0 // indirect
57-
github.com/vmihailenco/msgpack v4.0.4+incompatible // indirect
58-
github.com/vmihailenco/msgpack/v4 v4.3.12 // indirect
59-
github.com/vmihailenco/tagparser v0.1.1 // indirect
60-
github.com/zclconf/go-cty v1.11.0 // indirect
61-
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d // indirect
62-
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2 // indirect
63-
golang.org/x/sys v0.0.0-20220627191245-f75cf1eec38b // indirect
64-
golang.org/x/text v0.3.7 // indirect
65-
google.golang.org/appengine v1.6.6 // indirect
66-
google.golang.org/genproto v0.0.0-20200711021454-869866162049 // indirect
67-
google.golang.org/grpc v1.48.0 // indirect
68-
google.golang.org/protobuf v1.28.1 // indirect
69-
)
3+
go 1.19

0 commit comments

Comments
 (0)