page_title | subcategory | description |
---|---|---|
twc_firewall_rule Resource - Timeweb Cloud |
Resource for describing needed firewall rule and provides actual information about its status |
Resource for describing needed firewall rule and provides actual information about its status
// Create example firewall
resource "twc_firewall" "example-firewall" {
name = "example-firewall"
description = "Some example firewall"
}
// Add rule to created firewall that allow TCP on 80 port from any source
resource "twc_firewall_rule" "example-firewall-rules" {
firewall_id = resource.twc_firewall.example-firewall.id
description = "Some example firewall rule"
direction = "ingress"
port = 80
protocol = "tcp"
cidr = "0.0.0.0/0"
}
direction
(String) Rule directionfirewall_id
(String) ID of target firewallprotocol
(String) Rule protocol
cidr
(String) Rule CIDRdescription
(String) Description for firewallport
(Number) Port when rule protocol is TCP or UDP
id
(String) The ID of this resource.