Documentation ¶
Index ¶
- Constants
- func AttachmentResource() *schema.Resource
- func ByID(t *testing.T, firewall *hcloud.Firewall) func(*hcloud.Client, int) bool
- func DataSource() *schema.Resource
- func DataSourceList() *schema.Resource
- func Resource() *schema.Resource
- func Sweep(r string) error
- type DData
- type DDataList
- type RData
- type RDataApplyTo
- type RDataAttachment
- type RDataRule
Constants ¶
const ( // DataSourceType is the type name of the Hetzner Cloud Firewall resource. DataSourceType = "hcloud_firewall" // DataSourceListType is the type name to receive a list of Hetzner Cloud Firewall resources. DataSourceListType = "hcloud_firewalls" )
const AttachmentResourceType = "hcloud_firewall_attachment"
AttachmentResourceType is the type of the hcloud_firewall_attachment resource.
const ResourceType = "hcloud_firewall"
ResourceType is the type name of the Hetzner Cloud Firewall resource.
Variables ¶
This section is empty.
Functions ¶
func AttachmentResource ¶ added in v1.33.0
AttachmentResource defines the schema for the hcloud_firewall_attachment resource.
func DataSource ¶
func DataSourceList ¶ added in v1.31.0
Types ¶
type DData ¶
type DData struct { testtemplate.DataCommon FirewallID string FirewallName string LabelSelector string }
DData defines the fields for the "testdata/d/hcloud_firewall" template.
type DDataList ¶ added in v1.31.0
type DDataList struct { testtemplate.DataCommon LabelSelector string }
DDataList defines the fields for the "testdata/d/hcloud_firewalls" template.
type RData ¶
type RData struct { testtemplate.DataCommon Name string Rules []RDataRule ApplyTo []RDataApplyTo Labels map[string]string }
RData defines the fields for the "testdata/r/hcloud_firewall" template.
type RDataApplyTo ¶ added in v1.31.0
type RDataAttachment ¶ added in v1.33.0
type RDataAttachment struct { testtemplate.DataCommon FirewallIDRef string ServerIDRefs []string LabelSelectors []string }
RDataAttachment defines the fields for the "testdata/r/hcloud_firewall_attachment" template.
Fields ending in Ref are meant to contain a string referencing a Terraform value.
func NewRDataAttachment ¶ added in v1.33.0
func NewRDataAttachment(resName, fwIDRef string) *RDataAttachment
NewRDataAttachment creates a new RDataAttachment with the passed terraform resource name. It references a firewall using fwIDRef.
func (*RDataAttachment) TFID ¶ added in v1.33.0
func (d *RDataAttachment) TFID() string
TFID returns the resource identifier.