HomeComputeInstancesAPI/CLI
Scaleway CLI Cheatsheet

Jump toUpdate content

Scaleway Instances CLI Cheatsheet

This page shows the most common Scaleway CLI commands for creating and managing Scaleway Instances.

Identity and Access Management (IAM):

If you have activated IAM, you may need certain IAM permissions to carry out some actions described on this page. This means:

  • you are the Owner of the Scaleway Organization in which the actions will be carried out, or
  • you are an IAM user of the Organization, with a policy granting you the necessary permission sets
Tip:

This content is also available as a wallpaper (.png file) and as a printable PDF file. Click the links below to download:

Managing Instances

# Create Instance
scw instance server create type=<instance-type> zone=<availability-zone> image=<image-uuid> root-volume=l:<volume-size> name=<instance-name> ip=new project-id=<scw-project-id>

# Connect to Instance
ssh root@<instance-ip>

Managing flexible IP addresses

# Detach IP
scw instance ip detach <ip-address>

# Attach IP
scw instance ip attach <ip-address> server-id=<instance-uuid>

Using Private Networks

# Create Private Network
scw vpc private-network create name=<private-network-name>

# List Private Networks
scw vpc private-network list

# Attach Private Network
scw instance private-nic create server-id=<instance-uuid> private-network-id=<private-network-uuid>

# Detach Private Network
scw instance private-nic delete server-id=<instance-uuid> private-nic-id=<private-nic-uuid>

# Delete Private Network
scw vpc private-network delete <private-network-uuid>

Creating backups

scw instance server backup <instance-uuid>  

Managing snapshots

# List volumes
scw instance volume list

# Create snapshot
scw instance snapshot create volume-id=<volume-uuid>

# List snapshots
scw instance snapshot list

# Create an image from a snapshot
scw instance image create snapshot-id=<snapshot-id> arch=<architecture-of-the-image>

# Delete snapshot
scw instance snapshot delete <snapshot-uuid>

Boot modes

Standby

# Put Instance in standby mode
scw instance server standby <instance-uuid>

Reboot

# Reboot Instance
scw instance server reboot <instance-uuid>

Power

# Power Instance OFF
scw instance server stop <instance-uuid>

# Power Instance OFF
scw instance server start <instance-uuid>