mirror of
https://github.com/opentofu/opentofu.git
synced 2025-01-15 19:22:46 -06:00
39 lines
776 B
Go
39 lines
776 B
Go
package aws
|
|
|
|
import (
|
|
"github.com/hashicorp/terraform/terraform"
|
|
)
|
|
|
|
type ResourceProvider struct {
|
|
}
|
|
|
|
func (p *ResourceProvider) Configure(*terraform.ResourceConfig) error {
|
|
return nil
|
|
}
|
|
|
|
func (p *ResourceProvider) Diff(
|
|
s *terraform.ResourceState,
|
|
c *terraform.ResourceConfig) (*terraform.ResourceDiff, error) {
|
|
return &terraform.ResourceDiff{
|
|
Attributes: map[string]*terraform.ResourceAttrDiff{
|
|
"id": &terraform.ResourceAttrDiff{
|
|
Old: "",
|
|
NewComputed: true,
|
|
RequiresNew: true,
|
|
},
|
|
"created": &terraform.ResourceAttrDiff{
|
|
Old: "false",
|
|
New: "true",
|
|
},
|
|
},
|
|
}, nil
|
|
}
|
|
|
|
func (p *ResourceProvider) Resources() []terraform.ResourceType {
|
|
return []terraform.ResourceType{
|
|
terraform.ResourceType{
|
|
Name: "aws_instance",
|
|
},
|
|
}
|
|
}
|