-
Notifications
You must be signed in to change notification settings - Fork 5
/
GNUmakefile
43 lines (36 loc) · 1.04 KB
/
GNUmakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
default: testacc
version="0.0.0-canary"
chip=amd64
ifeq ($(shell uname -m), arm64)
chip=arm64
endif
ifeq ($(shell uname -s),Linux)
os="linux"
endif
ifeq ($(shell uname -s),Darwin)
os="darwin"
endif
# Run acceptance tests
.PHONY: testacc
testacc:
TF_ACC=1 go test ./... -v $(TESTARGS) -timeout 120m
local-sdk:
go mod edit -replace github.com/checkly/checkly-go-sdk=../checkly-go-sdk
dev:
# for dev purposes only, build the provider and install
# it as dev/checkly/check + version number
go build -o terraform-provider-checkly
mkdir -p ~/.terraform.d/plugins/dev/checkly/checkly/${version}/${os}_${chip}/
chmod +x terraform-provider-checkly
mv terraform-provider-checkly ~/.terraform.d/plugins/dev/checkly/checkly/${version}/${os}_${chip}/terraform-provider-checkly_v${version}
cd demo && rm -f .terraform.lock.hcl
cd demo && TF_LOG=TRACE terraform init -upgrade
cd local && rm -f .terraform.lock.hcl
cd local && TF_LOG=TRACE terraform init -upgrade
fmt:
go fmt ./checkly
terraform fmt
doc:
./tools/tfplugindocs
generate:
go generate ./...