config_profile_interfaces
Creates, updates, deletes, gets or lists a config_profile_interfaces
resource.
Overview
Name | config_profile_interfaces |
Type | Resource |
Id | linode.linode.config_profile_interfaces |
Fields
The following fields are returned by SELECT
queries:
- get_linode_config_interface
- get_linode_config_interfaces
A configuration interface object.
Name | Datatype | Description |
---|---|---|
id | integer | Read-only The unique ID representing this interface. |
subnet_id | integer | The id of the VPC subnet for this interface. Use this value in a request to assign a Linode to a VPC subnet. - Required for vpc type interfaces. - Returned as null for non-vpc type interfaces. - Once you've assigned a VPC subnet to an interface, you can't update it. - You need to reboot a Linode using the interface's configuration profile to assign the Linode to a VPC subnet. |
vpc_id | integer | Read-only The id of the VPC configured for this interface. Returned as null for non-vpc type interfaces. |
active | boolean | Read-only Returns true if the interface is in use, meaning that the Linode has been booted using the configuration profile to which the interface belongs. |
ip_ranges | array | IPv4 CIDR VPC subnet ranges that are routed to this interface. When included in a request: - A range can't include any addresses that are assigned to an active Linode or another VPC subnet. - When updating, you need to include any existing ranges to maintain them. If a range is left out, it will be removed. - Submit this as an empty array removes all existing values. - Omit this object to leave existing values as is. <<LB>> > 📘 > > This is only supported for interfaces with a purpose of vpc . |
ipam_address | string (ip/netmask) | This interface's private IP address in classless inter-domain routing (CIDR) notation. For interfaces with a purpose of public : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. For interfaces with a purpose of vlan : - To avoid conflicting addresses, make sure this value is unique for each vlan interface. - This should be unique among devices attached to the VLAN to avoid conflict. - If Network Helper is enabled, the Linode's interface will be automatically configured to use this address after the Linode is rebooted. If Network Helper is disabled, enable the address using manual static IP configuration. For interfaces with a purpose of vpc : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. (example: 10.0.0.1/24) |
ipv4 | object | IPv4 addresses configured for this interface. This only applies to interfaces with a purpose of vpc . Returned as null if no vpc interface is assigned. |
label | string | Filterable The name of this interface. For interfaces with a purpose of vlan : - Required. - This needs to be unique among a Linode's interfaces. A Linode can't be attached to the same VLAN multiple times. - This can only contain ASCII letters, numbers, and dashes (- ). You can't use two consecutive dashes (-- ). - If the VLAN label is new, a VLAN is created. Up to 10 VLANs can be created in each data center region . To view your active VLANs, run the List VLANs operation. For interfaces with a purpose of public : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. For interfaces with a purpose of vpc : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. (example: example-interface, pattern: [a-zA-Z0-9-]+ ) |
primary | boolean | The default route to the Linode. Each Linode can have one interface set as its primary . If you haven't specifically set a primary , the first non-vlan type interface is automatically treated as the primary. > 📘 > > This needs to be set to false for any interface that uses vlan as its purpose . |
purpose | string | The type of interface. This can be public , vlan , or vpc . For interfaces with a purpose of public : - You can only define one public interface per Linode. - The Linode's default public IPv4 address is assigned to the public interface. - A Linode needs a public interface in the first or eth0 position to be reachable via the public internet, after it boots. If no public interface is configured, you can only access the Linode through LISH, or through another Linode that's connected to the same VLAN or VPC. For interfaces with a purpose of vlan : - Configuring this purpose of interface attaches a Linode to the VLAN with the specified label . - If an ipam_address is configured, the Linode uses this address. For interfaces with a purpose of vpc : - Configuring this purpose of interface attaches a Linode to an existing VPC subnet with the specified subnet_id . - When the interface is activated, the Linode is configured to use an IP address from the range in the assigned VPC subnet. See ipv4.vpc for more information. (example: vlan) |
An ordered array of configuration profile interface objects.
Name | Datatype | Description |
---|---|---|
id | integer | Read-only The unique ID representing this interface. |
subnet_id | integer | The id of the VPC subnet for this interface. Use this value in a request to assign a Linode to a VPC subnet. - Required for vpc type interfaces. - Returned as null for non-vpc type interfaces. - Once you've assigned a VPC subnet to an interface, you can't update it. - You need to reboot a Linode using the interface's configuration profile to assign the Linode to a VPC subnet. |
vpc_id | integer | Read-only The id of the VPC configured for this interface. Returned as null for non-vpc type interfaces. |
active | boolean | Read-only Returns true if the interface is in use, meaning that the Linode has been booted using the configuration profile to which the interface belongs. |
ip_ranges | array | IPv4 CIDR VPC subnet ranges that are routed to this interface. When included in a request: - A range can't include any addresses that are assigned to an active Linode or another VPC subnet. - When updating, you need to include any existing ranges to maintain them. If a range is left out, it will be removed. - Submit this as an empty array removes all existing values. - Omit this object to leave existing values as is. <<LB>> > 📘 > > This is only supported for interfaces with a purpose of vpc . |
ipam_address | string (ip/netmask) | This interface's private IP address in classless inter-domain routing (CIDR) notation. For interfaces with a purpose of public : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. For interfaces with a purpose of vlan : - To avoid conflicting addresses, make sure this value is unique for each vlan interface. - This should be unique among devices attached to the VLAN to avoid conflict. - If Network Helper is enabled, the Linode's interface will be automatically configured to use this address after the Linode is rebooted. If Network Helper is disabled, enable the address using manual static IP configuration. For interfaces with a purpose of vpc : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. (example: 10.0.0.1/24) |
ipv4 | object | IPv4 addresses configured for this interface. This only applies to interfaces with a purpose of vpc . Returned as null if no vpc interface is assigned. |
label | string | Filterable The name of this interface. For interfaces with a purpose of vlan : - Required. - This needs to be unique among a Linode's interfaces. A Linode can't be attached to the same VLAN multiple times. - This can only contain ASCII letters, numbers, and dashes (- ). You can't use two consecutive dashes (-- ). - If the VLAN label is new, a VLAN is created. Up to 10 VLANs can be created in each data center region . To view your active VLANs, run the List VLANs operation. For interfaces with a purpose of public : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. For interfaces with a purpose of vpc : - If you include this in a request, set it to an empty string ("" ) or null . - Returned as null in a response. (example: example-interface, pattern: [a-zA-Z0-9-]+ ) |
primary | boolean | The default route to the Linode. Each Linode can have one interface set as its primary . If you haven't specifically set a primary , the first non-vlan type interface is automatically treated as the primary. > 📘 > > This needs to be set to false for any interface that uses vlan as its purpose . |
purpose | string | The type of interface. This can be public , vlan , or vpc . For interfaces with a purpose of public : - You can only define one public interface per Linode. - The Linode's default public IPv4 address is assigned to the public interface. - A Linode needs a public interface in the first or eth0 position to be reachable via the public internet, after it boots. If no public interface is configured, you can only access the Linode through LISH, or through another Linode that's connected to the same VLAN or VPC. For interfaces with a purpose of vlan : - Configuring this purpose of interface attaches a Linode to the VLAN with the specified label . - If an ipam_address is configured, the Linode uses this address. For interfaces with a purpose of vpc : - Configuring this purpose of interface attaches a Linode to an existing VPC subnet with the specified subnet_id . - When the interface is activated, the Linode is configured to use an IP address from the range in the assigned VPC subnet. See ipv4.vpc for more information. (example: vlan) |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get_linode_config_interface | select | Returns a single configuration profile interface. To access this operation, your user needs at least the read_only grant for the Linode.Learn more... Learn more... | ||
get_linode_config_interfaces | select | Returns all configuration profile interfaces assigned to a specific configuration profile, on a specific Linode. To access this operation, your user needs the read_write grant for the Linode.Learn more... Learn more... | ||
post_linode_config_interface | insert | data__purpose | Creates and appends a single interface to the end of the interfaces array for an existing configuration profile. After you add the interface, you need to reboot the target Linode.- To access this operation, your user needs the read_write grant for the Linode.- A successful request triggers a linode_config_update event.- Only one interface can be set as primary . Setting primary to true for an interface sets all other interfaces to false .Learn more... Learn more... | |
put_linode_config_interface | replace | Update a vpc or public configuration profile interface for a specific configuration profile, on a specific Linode.- To access this operation, your user needs the read_write grant for the Linode.- A successful request triggers a linode_config_update event.- Only certain attributes can be updated for a configuration profile interface. You need to add a new configuration profile interface on your Linode if you need new values for any other attribute. Here are the supported objects, based on the interface's purpose :- public . The primary attribute.- vpc . The ip_ranges , ipv4 , or primary attributes.- You can't update a configuration profile with a purpose of vlan .Learn more... Learn more... | ||
delete_linode_config_interface | delete | Deletes a configuration profile interface from a specific configuration profile, on a specific Linode. - To access this operation, your user needs the read_write grant for the Linode.- A successful request triggers a linode_config_update event.- You can't delete an active configuration profile interface. First, you need to shut down the associated Linode or restart it using another configuration profile. Learn more... Learn more... | ||
post_linode_config_interfaces | exec | ids | Reorders the existing Interfaces of a Configuration Profile. - The User accessing this operation must have read_write grants to the Linode.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.
Name | Datatype | Description |
---|
SELECT
examples
- get_linode_config_interface
- get_linode_config_interfaces
Returns a single configuration profile interface. To access this operation, your user needs at least the read_only
grant for the Linode.
Learn more...
Learn more...
SELECT
id,
subnet_id,
vpc_id,
active,
ip_ranges,
ipam_address,
ipv4,
label,
primary,
purpose
FROM linode.linode.config_profile_interfaces;
Returns all configuration profile interfaces assigned to a specific configuration profile, on a specific Linode. To access this operation, your user needs the read_write
grant for the Linode.
Learn more...
Learn more...
SELECT
id,
subnet_id,
vpc_id,
active,
ip_ranges,
ipam_address,
ipv4,
label,
primary,
purpose
FROM linode.linode.config_profile_interfaces;
INSERT
examples
- post_linode_config_interface
- Manifest
Creates and appends a single interface to the end of the interfaces
array for an existing configuration profile. After you add the interface, you need to reboot the target Linode.
- To access this operation, your user needs the read_write
grant for the Linode.
- A successful request triggers a linode_config_update
event.
- Only one interface can be set as primary
. Setting primary
to true
for an interface sets all other interfaces to false
.
Learn more...
Learn more...
INSERT INTO linode.linode.config_profile_interfaces (
data__ip_ranges,
data__ipam_address,
data__ipv4,
data__label,
data__primary,
data__purpose,
data__subnet_id
)
SELECT
'{{ ip_ranges }}',
'{{ ipam_address }}',
'{{ ipv4 }}',
'{{ label }}',
{{ primary }},
'{{ purpose }}' --required,
{{ subnet_id }}
RETURNING
id,
subnet_id,
vpc_id,
active,
ip_ranges,
ipam_address,
ipv4,
label,
primary,
purpose
;
# Description fields are for documentation purposes
- name: config_profile_interfaces
props:
- name: ip_ranges
value: array
description: >
IPv4 CIDR VPC subnet ranges that are routed to this interface.
When included in a request:
- A range can't include any addresses that are assigned to an active Linode or another VPC subnet.
- When updating, you need to include any existing ranges to maintain them. If a range is left out, it will be removed.
- Submit this as an empty array removes all existing values.
- Omit this object to leave existing values as is.
<<LB>>
> 📘
>
> This is only supported for interfaces with a `purpose` of `vpc`.
- name: ipam_address
value: string
description: >
This interface's private IP address in classless inter-domain routing (CIDR) notation.
For interfaces with a `purpose` of `public`:
- If you include this in a request, set it to an empty string (`""`) or `null`.
- Returned as `null` in a response.
For interfaces with a `purpose` of `vlan`:
- To avoid conflicting addresses, make sure this value is unique for each `vlan` interface.
- This should be unique among devices attached to the VLAN to avoid conflict.
- If Network Helper is enabled, the Linode's interface will be automatically configured to use this address after the Linode is rebooted. If Network Helper is disabled, enable the address using [manual static IP configuration](https://www.linode.com/docs/guides/manual-network-configuration/).
For interfaces with a `purpose` of `vpc`:
- If you include this in a request, set it to an empty string (`""`) or `null`.
- Returned as `null` in a response.
- name: ipv4
value: object
description: >
IPv4 addresses configured for this interface. This only applies to interfaces with a `purpose` of `vpc`. Returned as `null` if no `vpc` interface is assigned.
- name: label
value: string
description: >
__Filterable__ The name of this interface.
For interfaces with a `purpose` of `vlan`:
- Required.
- This needs to be unique among a Linode's interfaces. A Linode can't be attached to the same VLAN multiple times.
- This can only contain ASCII letters, numbers, and dashes (`-`). You can't use two consecutive dashes (`--`).
- If the VLAN label is new, a VLAN is created. Up to 10 VLANs can be created in each data center `region`. To view your active VLANs, run the [List VLANs](https://techdocs.akamai.com/linode-api/reference/get-vlans) operation.
For interfaces with a `purpose` of `public`:
- If you include this in a request, set it to an empty string (`""`) or `null`.
- Returned as `null` in a response.
For interfaces with a `purpose` of `vpc`:
- If you include this in a request, set it to an empty string (`""`) or `null`.
- Returned as `null` in a response.
- name: primary
value: boolean
description: >
The default route to the Linode. Each Linode can have one interface set as its `primary`. If you haven't specifically set a `primary`, the first non-`vlan` type interface is automatically treated as the primary.
> 📘
>
> This needs to be set to `false` for any interface that uses `vlan` as its `purpose`.
- name: purpose
value: string
description: >
The type of interface. This can be `public`, `vlan`, or `vpc`.
For interfaces with a `purpose` of `public`:
- You can only define one `public` interface per Linode.
- The Linode's default public IPv4 address is assigned to the `public` interface.
- A Linode needs a `public` interface in the first or `eth0` position to be reachable via the public internet, after it boots. If no `public` interface is configured, you can only access the Linode through [LISH](https://www.linode.com/docs/products/compute/compute-instances/guides/lish/), or through another Linode that's connected to the same VLAN or VPC.
For interfaces with a `purpose` of `vlan`:
- Configuring this `purpose` of interface attaches a Linode to the VLAN with the specified `label`.
- If an `ipam_address` is configured, the Linode uses this address.
For interfaces with a `purpose` of `vpc`:
- Configuring this `purpose` of interface attaches a Linode to an existing VPC subnet with the specified `subnet_id`.
- When the interface is activated, the Linode is configured to use an IP address from the range in the assigned VPC subnet. See `ipv4.vpc` for more information.
valid_values: ['public', 'vlan', 'vpc']
- name: subnet_id
value: integer
description: >
The `id` of the VPC subnet for this interface. Use this value in a request to assign a Linode to a VPC subnet.
- Required for `vpc` type interfaces.
- Returned as `null` for non-`vpc` type interfaces.
- Once you've assigned a VPC subnet to an interface, you can't update it.
- You need to reboot a Linode using the interface's configuration profile to assign the Linode to a VPC subnet.
REPLACE
examples
- put_linode_config_interface
Update a vpc
or public
configuration profile interface for a specific configuration profile, on a specific Linode.
- To access this operation, your user needs the read_write
grant for the Linode.
- A successful request triggers a linode_config_update
event.
- Only certain attributes can be updated for a configuration profile interface. You need to add a new configuration profile interface on your Linode if you need new values for any other attribute. Here are the supported objects, based on the interface's purpose
:
- public
. The primary
attribute.
- vpc
. The ip_ranges
, ipv4
, or primary
attributes.
- You can't update a configuration profile with a purpose
of vlan
.
Learn more...
Learn more...
REPLACE linode.linode.config_profile_interfaces
SET
data__ip_ranges = '{{ ip_ranges }}',
data__ipv4 = '{{ ipv4 }}',
data__primary = {{ primary }}
WHERE
RETURNING
id,
subnet_id,
vpc_id,
active,
ip_ranges,
ipam_address,
ipv4,
label,
primary,
purpose;
DELETE
examples
- delete_linode_config_interface
Deletes a configuration profile interface from a specific configuration profile, on a specific Linode.
- To access this operation, your user needs the read_write
grant for the Linode.
- A successful request triggers a linode_config_update
event.
- You can't delete an active configuration profile interface. First, you need to shut down the associated Linode or restart it using another configuration profile.
Learn more...
Learn more...
DELETE FROM linode.linode.config_profile_interfaces;
Lifecycle Methods
- post_linode_config_interfaces
Reorders the existing Interfaces of a Configuration Profile.
- The User accessing this operation must have read_write
grants to the Linode.
Learn more...
Learn more...
EXEC linode.linode.config_profile_interfaces.post_linode_config_interfaces
@@json=
'{
"ids": "{{ ids }}"
}';