Skip to content

Commit acf412e

Browse files
authored
chore(instance): remove support for creating a volume from a volume (#3497)
1 parent 1c51dc2 commit acf412e

File tree

5 files changed

+3
-26
lines changed

5 files changed

+3
-26
lines changed

cmd/scw/testdata/test-all-usage-instance-volume-create-usage.golden

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@ EXAMPLES:
1212
Create a volume with a size of 50GB
1313
scw instance volume create size=50GB
1414

15-
Create a volume of type 'l_ssd', based on volume '00112233-4455-6677-8899-aabbccddeeff'
16-
scw instance volume create volume-type=l_ssd base-volume=00112233-4455-6677-8899-aabbccddeeff
17-
1815
ARGS:
1916
[name=<generated>] Volume name
2017
[project-id] Project ID to use. If none is passed the default project ID will be used
@@ -25,9 +22,6 @@ ARGS:
2522
[organization-id] Organization ID to use. If none is passed the default organization ID will be used
2623
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | nl-ams-3 | pl-waw-1 | pl-waw-2 | pl-waw-3)
2724

28-
DEPRECATED ARGS:
29-
[base-volume] ID of the volume on which this volume will be based
30-
3125
FLAGS:
3226
-h, --help help for create
3327

docs/commands/instance.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2913,7 +2913,6 @@ scw instance volume create [arg=value ...]
29132913
| tags.{index} | | Volume tags |
29142914
| volume-type | One of: `l_ssd`, `b_ssd`, `unified`, `scratch`, `sbs_volume`, `sbs_snapshot` | Volume type |
29152915
| size | | Volume disk size, must be a multiple of 512 |
2916-
| ~~base-volume~~ | Deprecated | ID of the volume on which this volume will be based |
29172916
| base-snapshot | | ID of the snapshot on which this volume will be based |
29182917
| organization-id | | Organization ID to use. If none is passed the default organization ID will be used |
29192918
| zone | Default: `fr-par-1`<br />One of: `fr-par-1`, `fr-par-2`, `fr-par-3`, `nl-ams-1`, `nl-ams-2`, `nl-ams-3`, `pl-waw-1`, `pl-waw-2`, `pl-waw-3` | Zone to target. If none is passed will use default zone from the config |
@@ -2932,11 +2931,6 @@ Create a volume with a size of 50GB
29322931
scw instance volume create size=50GB
29332932
```
29342933

2935-
Create a volume of type 'l_ssd', based on volume '00112233-4455-6677-8899-aabbccddeeff'
2936-
```
2937-
scw instance volume create volume-type=l_ssd base-volume=00112233-4455-6677-8899-aabbccddeeff
2938-
```
2939-
29402934

29412935

29422936

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ require (
2424
github.com/moby/buildkit v0.11.6
2525
github.com/opencontainers/go-digest v1.0.0
2626
github.com/pkg/errors v0.9.1
27-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20231116153148-9180208cdea7
27+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20231117155000-b7672127ea65
2828
github.com/skratchdot/open-golang v0.0.0-20200116055534-eef842397966
2929
github.com/spf13/cobra v1.8.0
3030
github.com/spf13/pflag v1.0.5

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -490,8 +490,8 @@ github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDN
490490
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
491491
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06 h1:OkMGxebDjyw0ULyrTYWeN0UNCCkmCWfjPnIA2W6oviI=
492492
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06/go.mod h1:+ePHsJ1keEjQtpvf9HHw0f4ZeJ0TLRsxhunSI2hYJSs=
493-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20231116153148-9180208cdea7 h1:ZBmrDjGtiUGeX3HPeZ/4fcdMYnw1OnAl9ubl5e0h1nM=
494-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20231116153148-9180208cdea7/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg=
493+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20231117155000-b7672127ea65 h1:ecI+ocsfBfEGGRPWs9pLazW2klg2G8s/JHVQzSEZoBQ=
494+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20231117155000-b7672127ea65/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg=
495495
github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8=
496496
github.com/secure-systems-lab/go-securesystemslib v0.4.0 h1:b23VGrQhTA8cN2CbBw7/FulN9fTtqYUdS5+Oxzt+DUE=
497497
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=

internal/namespaces/instance/v1/instance_cli.go

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1715,13 +1715,6 @@ func instanceVolumeCreate() *core.Command {
17151715
Deprecated: false,
17161716
Positional: false,
17171717
},
1718-
{
1719-
Name: "base-volume",
1720-
Short: `ID of the volume on which this volume will be based`,
1721-
Required: false,
1722-
Deprecated: true,
1723-
Positional: false,
1724-
},
17251718
{
17261719
Name: "base-snapshot",
17271720
Short: `ID of the snapshot on which this volume will be based`,
@@ -1749,10 +1742,6 @@ func instanceVolumeCreate() *core.Command {
17491742
Short: "Create a volume with a size of 50GB",
17501743
ArgsJSON: `{"size":50000000000}`,
17511744
},
1752-
{
1753-
Short: "Create a volume of type 'l_ssd', based on volume '00112233-4455-6677-8899-aabbccddeeff'",
1754-
ArgsJSON: `{"base_volume":"00112233-4455-6677-8899-aabbccddeeff","volume_type":"l_ssd"}`,
1755-
},
17561745
},
17571746
}
17581747
}

0 commit comments

Comments
 (0)