-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathmain.go
More file actions
30 lines (23 loc) · 783 Bytes
/
main.go
File metadata and controls
30 lines (23 loc) · 783 Bytes
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
package main
import (
"flag"
// Embed timezone data for use in environments that may not have the
// timezone database available (e.g. scratch Docker images).
_ "time/tzdata"
"github.com/hashicorp/terraform-plugin-sdk/v2/plugin"
"github.com/coder/terraform-provider-coder/v2/provider"
)
// Run the docs generation tool, check its repository for more information on how it works and how docs
// can be customized.
//go:generate go run github.com/hashicorp/terraform-plugin-docs/cmd/tfplugindocs
func main() {
debug := flag.Bool("debug", false, "Enable debug mode for the provider")
flag.Parse()
opts := &plugin.ServeOpts{
Debug: *debug,
ProviderAddr: "registry.terraform.io/coder/coder",
ProviderFunc: provider.New,
}
servePprof()
plugin.Serve(opts)
}