Create a Rule Set

Beta Creates a Rule Set. A Rule Set is a named ordered set of Cloud Firewall rules. Rule Sets are designed to be reusable and are referenced in your Cloud Firewalls to help control access to network resources and services.

  • Rule Sets can be defined by users or managed services. Rule Sets created by a managed service cannot be modified, but you can view them. For example, LKE-E automatically creates and manages Rule Sets that allow cluster nodes to access necessary resources. You can review these rules, but LKE-E manages them for you.

  • Rule Sets capability is available for Linodes.

  • Rule Sets are versioned for auditing.

  • Rule Sets can be assigned to multiple firewalls, and each firewall can have multiple Rule Sets. However, Rule Sets can't reference other Rule Sets.

  • A rulesets_add event is generated when the firewall device is added successfully.

  • Prefix Lists can be referenced in Rule Sets.

linode-cli firewalls ruleset-create \
  --label ruleset123 \
  --description rulesetABC \
  --type "inbound" \
  --rules '[{"action":"ACCEPT", "description":"ABC-NeT-RuleSet", "protocol": "TCP", "ports": "22-24, 80, 443", "addresses": {"ipv4": ["192.0.2.0/24", "198.51.100.2/32", "pl::vpcs:1234", "pl::vpcs:<current>"], "ipv6": ["2001:DB8::/128", "pl::vpcs:1234", "pl::vpcs:<current>"]}}]'

<https://techdocs.akamai.com/cloud-computing/docs/getting-started-with-the-linode-cli>
firewall:read_write

<https://techdocs.akamai.com/linode-api/reference/get-started#oauth>
Path Params
string
enum
required

Enum Call either the v4 URL, or v4beta for operations still in Beta.

Allowed:
Body Params
string
length between 1 and 255

Describes this Rule Set. For display purposes only.

string | null

Filterable Unique, user-defined label for this Rule Set. This label helps you identify and describe your Rule Set.

rules
array of objects

The inbound or outbound access rules for the Rule Set. A Rule Set can have a total of 25 inbound and outbound rules. Multiple rules are applied in order. If two rules conflict, the first rule takes precedence. For example, if the first rule accepts inbound traffic from an address, and the second rule drops inbound traffic from the same address, the first rule applies, and inbound traffic from that address is accepted.

rules
string
enum

Indicates whether the Rule Set’s rules are for inbound or outbound traffic. This needs to match the type in the rule group in which it appears.

Allowed:
Responses

Language
Credentials
Response
Choose an example:
application/json