Skip to content

Commit 12894ec

Browse files
fix(ins): update images (#4099)
1 parent 046db49 commit 12894ec

File tree

1 file changed

+46
-15
lines changed

1 file changed

+46
-15
lines changed

compute/instances/how-to/create-an-instance.mdx

Lines changed: 46 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ content:
77
paragraph: This page explains how to create an Instance
88
tags: instance create
99
dates:
10-
validation: 2024-06-10
10+
validation: 2024-12-09
1111
posted: 2021-05-26
1212
categories:
1313
- compute
@@ -81,10 +81,10 @@ Select a tab below for instructions on how to create an Instance via either our
8181
- Booting from a volume that either lacks an OS or is among multiple volumes with identical operating systems can lead to inconsistent boot outcomes.
8282
</Message>
8383
<Message type="note">
84-
To use **[Block Storage Low Latency](/storage/block/) 15k**, your Instance must have at least **3 GiB/s of block bandwidth**.
85-
You can verify if an Instance type meets this requirement by consulting the [Scaleway Instances internet and Block Storage bandwidth overview](/compute/instances/reference-content/instances-bandwidth-overview/) documentation.
84+
To use **[Block Storage Low Latency](/storage/block/) 15k**, your Instance must have at least **3 GiB/s of block bandwidth**.
85+
You can verify if an Instance type meets this requirement by consulting the [Scaleway Instances internet and Block Storage bandwidth overview](/compute/instances/reference-content/instances-bandwidth-overview/) documentation.
8686

87-
Alternatively, use the [Instances API](https://www.scaleway.com/en/developers/api/instance/#path-instance-types-list-instance-types) to check the `block_bandwidth` field at `/instance/v1/zones/{zone}/products/servers`.
87+
Alternatively, use the [Instances API](https://www.scaleway.com/en/developers/api/instance/#path-instance-types-list-instance-types) to check the `block_bandwidth` field at `/instance/v1/zones/{zone}/products/servers`.
8888
This field provides detailed information about block bandwidth for each Instance type, helping you ensure compatibility with high-performance storage.
8989
</Message>
9090
- **Configure network** of the Instance.
@@ -109,7 +109,6 @@ Select a tab below for instructions on how to create an Instance via either our
109109
- A Scaleway account logged into the [console](https://console.scaleway.com)
110110
- [Owner](/identity-and-access-management/iam/concepts/#owner) status or [IAM permissions](/identity-and-access-management/iam/concepts/#permission) allowing you to perform actions in the intended Organization
111111
- An [SSH key](/identity-and-access-management/organizations-and-projects/how-to/create-ssh-key/)
112-
- An [SSH key](/identity-and-access-management/organizations-and-projects/how-to/create-ssh-key/)
113112
- A valid [API key](/identity-and-access-management/iam/how-to/create-api-keys/)
114113
- Installed [curl](https://curl.se/) on your local machine
115114

@@ -128,15 +127,39 @@ Select a tab below for instructions on how to create an Instance via either our
128127
export SCW_PROJECT_ID="<Project ID>"
129128
export SCW_DEFAULT_ZONE="<Availability Zone>"
130129
```
130+
2. Get the label of your OS of choice.
131+
132+
```
133+
curl --location "https://api.scaleway.com/marketplace/v2/images" \
134+
--header "X-Auth-Token: $SCW_SECRET_KEY"
131135
132-
2. Customize the **payload** for your API call. This payload specifies the configuration of the Instance you want to create. We provide an example payload below with all the required parameters, and a table of information to help you adapt it to your needs.
136+
{
137+
"images": [
138+
{
139+
"id": "607b12c2-685d-45f7-905f-57bc23863834",
140+
"name": "Ubuntu 24.04 Noble Numbat",
141+
"label": "ubuntu_noble",
142+
"description": "Ubuntu is the ideal distribution for scale-out computing, Ubuntu Server helps you make the most of your infrastructure.",
143+
"logo": "https://scw-marketplace-logos.s3.fr-par.scw.cloud/ubuntu.png",
144+
"categories": [
145+
"distribution"
146+
],
147+
"valid_until": null,
148+
"created_at": "2024-04-15T11:39:21.011004Z",
149+
"updated_at": "2024-10-09T07:32:04.494117Z"
150+
},
151+
],
152+
"total_count": 23
153+
}
154+
```
155+
3. Customize the **payload** for your API call. This payload specifies the configuration of the Instance you want to create. We provide an example payload below with all the required parameters, and a table of information to help you adapt it to your needs.
133156

134157
```
135158
{
136159
"name": "my-new-instance",
137160
"project": "'""$SCW_PROJECT_ID""'",
138161
"commercial_type": "GP1-S",
139-
"image": "544f0add-626b-4e4f-8a96-79fa4414d99a",
162+
"image": "ubuntu_noble",
140163
"enable_ipv6": true,
141164
"volumes
142165
"0": {
@@ -153,17 +176,17 @@ Select a tab below for instructions on how to create an Instance via either our
153176
| name | A name of your choice for the Instance (string) | Any string containing only alphanumeric characters, dots, spaces and dashes, e.g. `"my-new-instance"`. |
154177
| project | The Project in which the Instance should be created (string)| Any valid Scaleway Project ID (see above), e.g. `"b4bd99e0-b389-11ed-afa1-0242ac120002"` |
155178
| commercial-type | The commercial Instance type to create (string) | Any valid ID of a Scaleway commercial Instance type, e.g. `"GP1-S"`, `"PRO2-M"`. Use the [List Instance Types](https://www.scaleway.com/en/developers/api/instance/#path-instance-types-list-instance-types) endpoint to get a list of all valid Instance types and their IDs. |
156-
| image | The image to install on the Instance, e.g. a particular OS (string) | Any valid Scaleway image ID, e.g. `"544f0add-626b-4e4f-8a96-79fa4414d99a"` which is the ID for the `Ubuntu 22.04 Jammy Jellyfish` image. Use the [Marketplace API](https://www.scaleway.com/en/developers/api/marketplace/) endpoint to find available images and their IDs. |
179+
| image | The image to install on the Instance, e.g. a particular OS (string) | Any valid Scaleway image label, e.g. `ubuntu_noble` which is the label for the Ubuntu 24.04 Noble Numbat image. |
157180
| enable_ipv6 | Whether to enable IPv6 on the Instance (boolean) | `true` or `false` |
158181
| volumes | An object that specifies the storage volumes to attach to the Instance. Must respect the volume constraints of the `commercial_type` (i.e. for each type of Instance, a minimum amount of storage is required, and there is also a maximum that cannot be exceeded. Some Instance types support only Block Storage (`b_ssd`), others also support Local Storage (`l_ssd`) ). These constraints are available at the [List Instance Types](https://www.scaleway.com/en/developers/api/instance/#path-instance-types-list-instance-types) endpoint, via the `volume_constraints` parameter for each type listed in the response | A (dictionary) object with a minimum of one key (`"0"`) whose value is another object containing the parameters `"name"` (a name for the volume), `"size"` (the size for the volume, in bytes), and `"volume_type"` (`"l_ssd"` or `"b_ssd"`). Additional keys for additional volumes should increment by 1 each time (the second volume would have a key of `1`.) Further parameters are available, and it is possible to attach existing volumes rather than creating a new one, or create a volume from a snapshot. For full details see [here](https://www.scaleway.com/en/developers/api/instance/#path-volumes). |
159182

160-
3. Use the following curl command, replacing the payload with the one you specified in step 2, to create your Instance.
183+
4. Use the following curl command, replacing the payload with the one you specified in step 2, to create your Instance.
161184

162185
```
163186
curl -X POST -H "Content-Type: application/json" \
164187
-H "X-Auth-Token: $SCW_SECRET_KEY" \
165188
"https://api.scaleway.com/instance/v1/zones/{$ZONE}/servers" \
166-
-d '{"name": "my-new-instance", "project": "'"$PROJECT_ID"'", "commercial_type": "GP1-S", "image":"544f0add-626b-4e4f-8a96-79fa4414d99a","enable_ipv6": true, "volumes":{"0":{"name": "my-volume","size": 300000000000,"volume_type": "l_ssd"}}}'
189+
-d '{"name": "my-new-instance", "project": "'"$PROJECT_ID"'", "commercial_type": "GP1-S", "image":"ubuntu_noble","enable_ipv6": true, "volumes":{"0":{"name": "my-volume","size": 300000000000,"volume_type": "l_ssd"}}}'
167190
```
168191

169192
Valid Instance creation results in a `201` response containing a `server` object that confirms the attributes of your Instance.
@@ -190,15 +213,23 @@ Select a tab below for instructions on how to create an Instance via either our
190213
- A valid [API key](/identity-and-access-management/iam/how-to/create-api-keys/)
191214
- Installed and configured the [Scaleway CLI](https://github.com/scaleway/scaleway-cli) on your local machine
192215

216+
1. Get the label of your OS of choice.
217+
218+
```bash
219+
scw marketplace image list
220+
221+
ID LABEL NAME CATEGORIES VALID UNTIL
222+
607b12c2-685d-45f7-905f-57bc23863834 ubuntu_noble Ubuntu 24.04 Noble Numbat [distribution] -
223+
```
193224

194-
1. Prepare your command by choosing values for the parameters below to define the Instance you want to create. Use the table to select appropriate values.
225+
2. Prepare your command by choosing values for the parameters below to define the Instance you want to create. Use the table to select appropriate values.
195226

196227
```bash
197228
name=my-new-instance
198229
project-id=adcaffc9-38ef-4502-86e1-f70d3c353745
199230
zone=fr-par-1
200231
type=GP1-S
201-
image=544f0add-626b-4e4f-8a96-79fa4414d99a
232+
image=ubuntu_noble
202233
ip=new
203234
root-volume=l:300GB
204235
```
@@ -209,14 +240,14 @@ Select a tab below for instructions on how to create an Instance via either our
209240
| project-id | The Project in which the Instance should be created | Any valid Scaleway Project ID, e.g. `b4bd99e0-b389-11ed-afa1-0242ac120002` |
210241
| zone | The Availability Zone in which the Instance should be created. Note that some Instance types are only available in certain Availability Zones (see **type`**below) | Any valid Scaleway Availability Zone, e.g. `fr-par-1`, `pl-waw-2` |
211242
| type | The type of Instance to create | Any valid ID of a Scaleway Instance type, e.g. `GP1-S`, `PRO2-M`. Use the [server-type](https://github.com/scaleway/scaleway-cli/blob/master/docs/commands/instance.md#server-type-management-commands) command to get a list of all valid Instance types and their IDs. The default value is `DEV1-S` |
212-
| image | The image to install on the Instance, e.g. a particular OS | Any valid Scaleway image ID or its label, e.g. `544f0add-626b-4e4f-8a96-79fa4414d99a` or`ubutunu_jammy` for the Ubuntu 22.04 Jammy Jellyfish image. The default value is `ubuntu_jammy`. Use the [marketplace](https://github.com/scaleway/scaleway-cli/blob/master/docs/commands/marketplace.md) command to get a list of all available images and their IDs. |
243+
| image | The image to install on the Instance, e.g. a particular OS | Any valid Scaleway image label, e.g. `ubuntu_noble` which is the label for the Ubuntu 24.04 Noble Numbat image. |
213244
| ip | The IP address to use for the Instance. | `new` to create a new IP, `dynamic` to create a dynamic IP address, `none` for no public IP address, or an existing IP ID. Default is `new` |
214245
| root-volume | The root volume for the Instance (type e.g. `l` (local) or `b` (block) followed by a colon and its required size e.g. `10GB`) | Any valid volume type and size that is coherent with the storage constraints of the Instance **type** (available via `scw instance server-type list`) |
215246

216-
2. Open a terminal and run the command below, with the parameters modified according to your needs as defined in step one.
247+
3. Open a terminal and run the command below, with the parameters modified according to your needs as defined in step one.
217248

218249
```bash
219-
scw instance server create name=my-new-instance project-id=2ea18278-847c-4c33-8111-9c2376ed921e zone=fr-par-1 type=GP1-S image=544f0add-626b-4e4f-8a96-79fa4414d99a ip=new root-volume=l:300GB
250+
scw instance server create name=my-new-instance project-id=2ea18278-847c-4c33-8111-9c2376ed921e zone=fr-par-1 type=GP1-S image=ubuntu_noble ip=new root-volume=l:300GB
220251
```
221252

222253
Your Instance is created, and its details are returned to you in response.

0 commit comments

Comments
 (0)