builtin: fix all compilation

This commit is contained in:
Mitchell Hashimoto 2014-09-28 11:51:39 -07:00
parent 1e3dbee278
commit e2534e4210
14 changed files with 63 additions and 14 deletions

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/providers/aws"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(aws.ResourceProvider))
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: func() terraform.ResourceProvider {
return new(aws.ResourceProvider)
},
})
}

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/providers/cloudflare"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(cloudflare.ResourceProvider))
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: func() terraform.ResourceProvider {
return new(cloudflare.ResourceProvider)
},
})
}

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/providers/consul"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(consul.ResourceProvider))
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: func() terraform.ResourceProvider {
return new(consul.ResourceProvider)
},
})
}

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/providers/digitalocean"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(digitalocean.ResourceProvider))
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: func() terraform.ResourceProvider {
return new(digitalocean.ResourceProvider)
},
})
}

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/providers/dnsimple"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(dnsimple.ResourceProvider))
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: func() terraform.ResourceProvider {
return new(dnsimple.ResourceProvider)
},
})
}

View File

@ -6,5 +6,7 @@ import (
)
func main() {
plugin.Serve(google.Provider())
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: google.Provider,
})
}

View File

@ -6,5 +6,7 @@ import (
)
func main() {
plugin.Serve(heroku.Provider())
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: heroku.Provider,
})
}

View File

@ -6,5 +6,7 @@ import (
)
func main() {
plugin.Serve(mailgun.Provider())
plugin.Serve(&plugin.ServeOpts{
ProviderFunc: mailgun.Provider,
})
}

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/provisioners/file"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(file.ResourceProvisioner))
plugin.Serve(&plugin.ServeOpts{
ProvisionerFunc: func() terraform.ResourceProvisioner {
return new(file.ResourceProvisioner)
},
})
}

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/provisioners/local-exec"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(localexec.ResourceProvisioner))
plugin.Serve(&plugin.ServeOpts{
ProvisionerFunc: func() terraform.ResourceProvisioner {
return new(localexec.ResourceProvisioner)
},
})
}

View File

@ -3,8 +3,13 @@ package main
import (
"github.com/hashicorp/terraform/builtin/provisioners/remote-exec"
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
)
func main() {
plugin.Serve(new(remoteexec.ResourceProvisioner))
plugin.Serve(&plugin.ServeOpts{
ProvisionerFunc: func() terraform.ResourceProvisioner {
return new(remoteexec.ResourceProvisioner)
},
})
}

View File

@ -2,10 +2,11 @@ package google
import (
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/terraform"
)
// Provider returns a terraform.ResourceProvider.
func Provider() *schema.Provider {
func Provider() terraform.ResourceProvider {
return &schema.Provider{
Schema: map[string]*schema.Schema{
"account_file": &schema.Schema{

View File

@ -4,11 +4,12 @@ import (
"log"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/terraform"
"github.com/mitchellh/mapstructure"
)
// Provider returns a terraform.ResourceProvider.
func Provider() *schema.Provider {
func Provider() terraform.ResourceProvider {
return &schema.Provider{
Schema: map[string]*schema.Schema{
"email": &schema.Schema{

View File

@ -4,11 +4,12 @@ import (
"log"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/terraform"
"github.com/mitchellh/mapstructure"
)
// Provider returns a terraform.ResourceProvider.
func Provider() *schema.Provider {
func Provider() terraform.ResourceProvider {
return &schema.Provider{
Schema: map[string]*schema.Schema{
"api_key": &schema.Schema{