Skip to main content

firewalls

Creates, updates, deletes, gets or lists a firewalls resource.

Overview

Namefirewalls
TypeResource
Idlinode.nodebalancers.firewalls

Fields

The following fields are returned by SELECT queries:

Returns a paginated list of Firewalls assigned to this NodeBalancer.

NameDatatypeDescription
idintegerFilterable, Read-only The Firewall's unique ID.
createdstring (date-time)Filterable, Read-only When this Firewall was created. (example: 2018-01-01T00:01:01)
labelstringFilterable The Firewall's label, for display purposes only. Firewall labels have the following constraints: - Must begin and end with an alphanumeric character. - May only consist of alphanumeric characters, hyphens (-), underscores (_) or periods (.). - Cannot have two hyphens (--), underscores (__) or periods (..) in a row. - Must be between 3 and 32 characters. - Must be unique. (example: firewall123, pattern: ^a-zA-Z+$)
rulesobjectThe inbound and outbound access rules to apply to the Firewall. A Firewall may have up to 25 rules across its inbound and outbound rulesets. 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 the same address, the first rule applies and inbound traffic from that address is accepted.
statusstringRead-only The status of this Firewall. - When a Firewall is first created its status is enabled. - Run the Update a firewall operation to set a Firewall's status to enabled or disabled. - Run the Delete a firewall operation to delete a Firewall. (example: enabled)
tagsarrayFilterable An array of tags applied to this object. Tags are for organizational purposes only.
updatedstring (date-time)Filterable, Read-only When this Firewall was last updated. (example: 2018-01-02T00:01:01)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_node_balancer_firewallsselectView information for Firewalls assigned to this NodeBalancer.

Learn more...

Learn more...
put_node_balancer_firewallsreplacedata__firewall_idspage, page_sizeReplace the current list of assigned firewalls with a new list, or provide an empty list to remove all firewalls from this NodeBalancer.

Learn more...

Learn more...

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
pageintegerThe page of a collection to return.
page_sizeintegerThe number of items to return per page.

SELECT examples

View information for Firewalls assigned to this NodeBalancer.

Learn more...

Learn more...

SELECT
id,
created,
label,
rules,
status,
tags,
updated
FROM linode.nodebalancers.firewalls;

REPLACE examples

Replace the current list of assigned firewalls with a new list, or provide an empty list to remove all firewalls from this NodeBalancer.

Learn more...

Learn more...

REPLACE linode.nodebalancers.firewalls
SET
data__firewall_ids = '{{ firewall_ids }}'
WHERE
data__firewall_ids = '{{ firewall_ids }}' --required
AND page = '{{ page}}'
AND page_size = '{{ page_size}}'
RETURNING
data,
page,
pages,
results;