Skip to content

Commit

Permalink
fix(instance): set server type to required (#2502)
Browse files Browse the repository at this point in the history
  • Loading branch information
Codelax authored Sep 14, 2022
1 parent d2eb4a8 commit f3f8169
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ EXAMPLES:

ARGS:
image=ubuntu_jammy Image ID or label of the server
[type=DEV1-S] Server commercial type (GP1-XS | GP1-S | GP1-M | GP1-L | GP1-XL | DEV1-S | DEV1-M | DEV1-L | DEV1-XL | RENDER-S | STARDUST1-S | ENT1-S | ENT1-M | ENT1-L | ENT1-XL | ENT1-2XL | PRO2-XXS | PRO2-XS | PRO2-S | PRO2-M | PRO2-L | PLAY2-PICO | PLAY2-NANO | PLAY2-MICRO | GPU-3070-S)
type=DEV1-S Server commercial type (GP1-XS | GP1-S | GP1-M | GP1-L | GP1-XL | DEV1-S | DEV1-M | DEV1-L | DEV1-XL | RENDER-S | STARDUST1-S | ENT1-S | ENT1-M | ENT1-L | ENT1-XL | ENT1-2XL | PRO2-XXS | PRO2-XS | PRO2-S | PRO2-M | PRO2-L | PLAY2-PICO | PLAY2-NANO | PLAY2-MICRO | GPU-3070-S)
[name=<generated>] Server name
[root-volume] Local root volume of the server
[additional-volumes.{index}] Additional local and block volumes attached to your server
Expand Down
2 changes: 1 addition & 1 deletion docs/commands/instance.md
Original file line number Diff line number Diff line change
Expand Up @@ -1308,7 +1308,7 @@ scw instance server create [arg=value ...]
| Name | | Description |
|------|---|-------------|
| image | Required<br />Default: `ubuntu_jammy` | Image ID or label of the server |
| type | Default: `DEV1-S`<br />One of: `GP1-XS`, `GP1-S`, `GP1-M`, `GP1-L`, `GP1-XL`, `DEV1-S`, `DEV1-M`, `DEV1-L`, `DEV1-XL`, `RENDER-S`, `STARDUST1-S`, `ENT1-S`, `ENT1-M`, `ENT1-L`, `ENT1-XL`, `ENT1-2XL`, `PRO2-XXS`, `PRO2-XS`, `PRO2-S`, `PRO2-M`, `PRO2-L`, `PLAY2-PICO`, `PLAY2-NANO`, `PLAY2-MICRO`, `GPU-3070-S` | Server commercial type |
| type | Required<br />Default: `DEV1-S`<br />One of: `GP1-XS`, `GP1-S`, `GP1-M`, `GP1-L`, `GP1-XL`, `DEV1-S`, `DEV1-M`, `DEV1-L`, `DEV1-XL`, `RENDER-S`, `STARDUST1-S`, `ENT1-S`, `ENT1-M`, `ENT1-L`, `ENT1-XL`, `ENT1-2XL`, `PRO2-XXS`, `PRO2-XS`, `PRO2-S`, `PRO2-M`, `PRO2-L`, `PLAY2-PICO`, `PLAY2-NANO`, `PLAY2-MICRO`, `GPU-3070-S` | Server commercial type |
| name | Default: `<generated>` | Server name |
| root-volume | | Local root volume of the server |
| additional-volumes.{index} | | Additional local and block volumes attached to your server |
Expand Down
7 changes: 4 additions & 3 deletions internal/namespaces/instance/v1/custom_server_create.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,10 @@ func serverCreateCommand() *core.Command {
AutoCompleteFunc: instanceServerCreateImageAutoCompleteFunc,
},
{
Name: "type",
Short: "Server commercial type",
Default: core.DefaultValueSetter("DEV1-S"),
Name: "type",
Short: "Server commercial type",
Default: core.DefaultValueSetter("DEV1-S"),
Required: true,
EnumValues: []string{
"GP1-XS",
"GP1-S",
Expand Down

0 comments on commit f3f8169

Please sign in to comment.