Scaleway logo
Commands

Documentation for `scw ipam`

The CLI documentation pages are currently under construction

The content is up to date. We're making improvements to the site over the next few weeks for a better experience.

This API allows you to manage your Scaleway IP addresses with our IP Address Management tool.

IP management command

*ips_long.

Attach private IP to custom resource

Attach an existing reserved private IP from a Private Network subnet to a custom, named resource via its MAC address. An example of a custom resource is a virtual machine hosted on an Elastic Metal server. Do not use this method for attaching IP addresses to standard Scaleway resources as it will fail - see the relevant product API for an equivalent method.

Usage:

TerminalCode
scw ipam ip attach <ip-id ...> [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
ip-idIP IDRequired
resource.mac-addressMAC address of the custom resource
resource.nameName of the custom resource
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw

Reserve a new IP

Reserve a new IP from the specified source. Currently IPs can only be reserved from a Private Network.

Usage:

TerminalCode
scw ipam ip create [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
project-idProject ID to use. If none is passed the default project ID will be used
source.zonalZone the IP lives in if the IP is a public zoned IP.
source.private-network-idPrivate Network the IP lives in if the IP is a private IP.
source.subnet-idPrivate Network subnet the IP lives in if the IP is a private IP in a Private Network.
source.vpc-id
source.regionalDefines whether the IP is a public regional IP.
is-ipv6Request an IPv6 instead of an IPv4
addressRequest this specific IP address in the specified source pool
tags.{index}Tags for the IP
resource.mac-addressMAC address of the custom resource
resource.nameName of the custom resource
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw

Release an IP

Release an IP not currently attached to a resource, and returns it to the available IP pool.

Usage:

TerminalCode
scw ipam ip delete <ip-id ...> [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
ip-idIP IDRequired
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw

Detach private IP from a custom resource

Detach a private IP from a custom resource. An example of a custom resource is a virtual machine hosted on an Elastic Metal server. Do not use this method for detaching IP addresses from standard Scaleway resources (e.g. Instances, Load Balancers) as it will fail - see the relevant product API for an equivalent method.

Usage:

TerminalCode
scw ipam ip detach <ip-id ...> [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
ip-idIP IDRequired
resource.mac-addressMAC address of the custom resource
resource.nameName of the custom resource
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw

Get an IP

Retrieve details of an existing IP, specified by its IP ID.

Usage:

TerminalCode
scw ipam ip get <ip-id ...> [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
ip-idIP IDRequired
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw

List existing IPs

List existing IPs in the specified region using various filters. For example, you can filter for IPs within a specified Private Network, or for public IPs within a specified Project. By default, the IPs returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field.

Usage:

TerminalCode
scw ipam ip list [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
order-bySort order of the returned IPsOne of: created_at_desc, created_at_asc, updated_at_desc, updated_at_asc, attached_at_desc, attached_at_asc, ip_address_desc, ip_address_asc, mac_address_desc, mac_address_asc
project-idProject ID to filter for. Only IPs belonging to this Project will be returned
zonalZone to filter for. Only IPs that are zonal, and in this zone, will be returned
regionalFilter on regional IPs only.
private-network-idPrivate Network to filter for.
subnet-idSubnet ID to filter for.
vpc-idVPC ID to filter for.
attachedDefines whether to filter only for IPs which are attached to a resource
resource-nameAttached resource name to filter for, only IPs attached to a resource with this string within their name will be returned.
resource-idResource ID to filter for. Only IPs attached to this resource will be returned
resource-ids.{index}Resource IDs to filter for. Only IPs attached to at least one of these resources will be returned
resource-typeResource type to filter for. Only IPs attached to this type of resource will be returnedOne of: unknown_type, custom, instance_server, instance_ip, instance_private_nic, lb_server, fip_ip, vpc_gateway, vpc_gateway_network, k8s_node, k8s_cluster, rdb_instance, redis_cluster, baremetal_server, baremetal_private_nic, llm_deployment, mgdb_instance, apple_silicon_server, apple_silicon_private_nic, serverless_container, serverless_function, vpn_gateway, ddl_datalab, kafka_cluster, bgp_endpoint, scbl_sedb_cluster, dtwh_deployment, sedb_cluster, msgq_cluster, edge_vpc_endpoint, dviz_cluster, nats_cluster
resource-types.{index}Resource types to filter for. Only IPs attached to these types of resources will be returnedOne of: unknown_type, custom, instance_server, instance_ip, instance_private_nic, lb_server, fip_ip, vpc_gateway, vpc_gateway_network, k8s_node, k8s_cluster, rdb_instance, redis_cluster, baremetal_server, baremetal_private_nic, llm_deployment, mgdb_instance, apple_silicon_server, apple_silicon_private_nic, serverless_container, serverless_function, vpn_gateway, ddl_datalab, kafka_cluster, bgp_endpoint, scbl_sedb_cluster, dtwh_deployment, sedb_cluster, msgq_cluster, edge_vpc_endpoint, dviz_cluster, nats_cluster
mac-addressMAC address to filter for. Only IPs attached to a resource with this MAC address will be returned
tags.{index}Tags to filter for, only IPs with one or more matching tags will be returned
is-ipv6Defines whether to filter only for IPv4s or IPv6s
ip-ids.{index}IP IDs to filter for. Only IPs with these UUIDs will be returned
source-vpc-id
organization-idOrganization ID to filter for. Only IPs belonging to this Organization will be returned
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw, all

Move private IP to a custom resource

Move an existing reserved private IP from one custom resource (e.g. a virtual machine hosted on an Elastic Metal server) to another custom resource. This will detach it from the first resource, and attach it to the second. Do not use this method for moving IP addresses between standard Scaleway resources (e.g. Instances, Load Balancers) as it will fail - see the relevant product API for an equivalent method.

Usage:

TerminalCode
scw ipam ip move <ip-id ...> [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
ip-idIP IDRequired
from-resource.mac-addressMAC address of the custom resource
from-resource.nameName of the custom resource
to-resource.mac-addressMAC address of the custom resource
to-resource.nameName of the custom resource
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw

Update an IP

Update parameters including tags of the specified IP.

Usage:

TerminalCode
scw ipam ip update <ip-id ...> [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
ip-idIP IDRequired
tags.{index}Tags for the IP
reverses.{index}.hostnameReverse domain name
reverses.{index}.addressIP corresponding to the hostname
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw

Management command for sets of IPs

*ips_long.

Release ipam resources

Release ipam resources.

Usage:

TerminalCode
scw ipam ip-set release [arg=value ...]

Arguments:

NameDescriptionArgument Specifications
ip-ids.{index}
regionRegion to target. If none is passed will use default region from the configDefault: fr-par
One of: fr-par, it-mil, nl-ams, pl-waw