Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 24 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -316,14 +316,14 @@ Create a new server but do not start it.

Options:

--bootscript="" Assign a bootscript
--commercial-type=VC1 Create a server with specific commercial-type C1, VC1, C2[S|M|L]
-e, --env="" Provide metadata tags passed to initrd (i.e., boot=resue INITRD_DEBUG=1)
-h, --help=false Print usage
--ip-address=dynamic Assign a reserved public IP, a 'dynamic' one or 'none'
--name="" Assign a name
--tmp-ssh-key=false Access your server without uploading your SSH key to your account
-v, --volume="" Attach additional volume (i.e., 50G)
--bootscript="" Assign a bootscript
--commercial-type=VC1S Create a server with specific commercial-type C1, VC1S, C2[S|M|L]
-e, --env="" Provide metadata tags passed to initrd (i.e., boot=resue INITRD_DEBUG=1)
-h, --help=false Print usage
--ip-address=dynamic Assign a reserved public IP, a 'dynamic' one or 'none'
--name="" Assign a name
--tmp-ssh-key=false Access your server without uploading your SSH key to your account
-v, --volume="" Attach additional volume (i.e., 50G)

Examples:

Expand Down Expand Up @@ -691,21 +691,21 @@ Run a command in a new server.

Options:

-a, --attach=false Attach to serial console
--bootscript="" Assign a bootscript
--commercial-type=VC1 Start a server with specific commercial-type C1, VC1, C2[SML]
-d, --detach=false Run server in background and print server ID
-e, --env="" Provide metadata tags passed to initrd (i.e., boot=rescue INITRD_DEBUG=1)
-g, --gateway="" Use a SSH gateway
-h, --help=false Print usage
--ip-address="" Assign a reserved public IP, a 'dynamic' one or 'none' (default to 'none' if gateway specified, 'dynamic' otherwise)
--name="" Assign a name
--rm=false Automatically remove the server when it exits
--show-boot=false Allows to show the boot
-T, --timeout=0 Set timeout value to seconds
--tmp-ssh-key=false Access your server without uploading your SSH key to your account
-u, --userdata="" Start a server with userdata predefined
-v, --volume="" Attach additional volume (i.e., 50G)
-a, --attach=false Attach to serial console
--bootscript="" Assign a bootscript
--commercial-type=VC1S Start a server with specific commercial-type C1, VC1S, C2[SML]
-d, --detach=false Run server in background and print server ID
-e, --env="" Provide metadata tags passed to initrd (i.e., boot=rescue INITRD_DEBUG=1)
-g, --gateway="" Use a SSH gateway
-h, --help=false Print usage
--ip-address="" Assign a reserved public IP, a 'dynamic' one or 'none' (default to 'none' if gateway specified, 'dynamic' otherwise)
--name="" Assign a name
--rm=false Automatically remove the server when it exits
--show-boot=false Allows to show the boot
-T, --timeout=0 Set timeout value to seconds
--tmp-ssh-key=false Access your server without uploading your SSH key to your account
-u, --userdata="" Start a server with userdata predefined
-v, --volume="" Attach additional volume (i.e., 50G)

Examples:

Expand Down Expand Up @@ -1184,6 +1184,7 @@ $ scw inspect myserver | jq '.[0].public_ip.address'
### master (unreleased)

* Fix bug when using SCW_COMMERCIAL_TYPE variable
* Switch to VC1S

View full [commits list](https://github.com/scaleway/scaleway-cli/compare/v1.8.1...master)

Expand Down
2 changes: 1 addition & 1 deletion examples/create-image-from-http.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ NAME=$(basename "${URL}")
SNAPSHOT_NAME=${NAME%.*}-$(date +%Y-%m-%d_%H:%M)
IMAGE_NAME=${IMAGE_NAME:-$SNAPSHOT_NAME}
IMAGE_BOOTSCRIPT=${IMAGE_BOOTSCRIPT:stable}
SCW_COMMERCIAL_TYPE=${SCW_COMMERCIAL_TYPE:-VC1}
SCW_COMMERCIAL_TYPE=${SCW_COMMERCIAL_TYPE:-VC1S}
VOLUME_SIZE=${VOLUME_SIZE:-50GB}
SCW_TARGET_ARCH=x86_64
if [ "$SCW_COMMERCIAL_TYPE" = "C1" ]; then
Expand Down
4 changes: 2 additions & 2 deletions pkg/api/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ type ScalewayServer struct {
// Organization is the owner of the server
Organization string `json:"organization,omitempty"`

// CommercialType is the commercial type of the server (i.e: C1, C2[SML], VC1)
// CommercialType is the commercial type of the server (i.e: C1, C2[SML], VC1S)
CommercialType string `json:"commercial_type,omitempty"`

// Location of the server
Expand Down Expand Up @@ -568,7 +568,7 @@ type ScalewayServerDefinition struct {
// Organization is the owner of the server
Organization string `json:"organization"`

// CommercialType is the commercial type of the server (i.e: C1, C2[SML], VC1)
// CommercialType is the commercial type of the server (i.e: C1, C2[SML], VC1S)
CommercialType string `json:"commercial_type"`

PublicIP string `json:"public_ip,omitempty"`
Expand Down
2 changes: 1 addition & 1 deletion pkg/cli/cmd_create.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ func init() {
cmdCreate.Flag.StringVar(&createEnv, []string{"e", "-env"}, "", "Provide metadata tags passed to initrd (i.e., boot=resue INITRD_DEBUG=1)")
cmdCreate.Flag.StringVar(&createVolume, []string{"v", "-volume"}, "", "Attach additional volume (i.e., 50G)")
cmdCreate.Flag.StringVar(&createIPAddress, []string{"-ip-address"}, "dynamic", "Assign a reserved public IP, a 'dynamic' one or 'none'")
cmdCreate.Flag.StringVar(&createCommercialType, []string{"-commercial-type"}, "VC1", "Create a server with specific commercial-type C1, VC1, C2[S|M|L]")
cmdCreate.Flag.StringVar(&createCommercialType, []string{"-commercial-type"}, "VC1S", "Create a server with specific commercial-type C1, VC1S, C2[S|M|L]")
cmdCreate.Flag.BoolVar(&createHelp, []string{"h", "-help"}, false, "Print usage")
cmdCreate.Flag.BoolVar(&createTmpSSHKey, []string{"-tmp-ssh-key"}, false, "Access your server without uploading your SSH key to your account")
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/cli/cmd_run.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ func init() {
cmdRun.Flag.BoolVar(&runDetachFlag, []string{"d", "-detach"}, false, "Run server in background and print server ID")
cmdRun.Flag.StringVar(&runGateway, []string{"g", "-gateway"}, "", "Use a SSH gateway")
cmdRun.Flag.StringVar(&runUserdatas, []string{"u", "-userdata"}, "", "Start a server with userdata predefined")
cmdRun.Flag.StringVar(&runCommercialType, []string{"-commercial-type"}, "VC1", "Start a server with specific commercial-type C1, VC1, C2[SML]")
cmdRun.Flag.StringVar(&runCommercialType, []string{"-commercial-type"}, "VC1S", "Start a server with specific commercial-type C1, VC1S, C2[SML]")
cmdRun.Flag.BoolVar(&runAutoRemove, []string{"-rm"}, false, "Automatically remove the server when it exits")
cmdRun.Flag.BoolVar(&runTmpSSHKey, []string{"-tmp-ssh-key"}, false, "Access your server without uploading your SSH key to your account")
cmdRun.Flag.BoolVar(&runShowBoot, []string{"-show-boot"}, false, "Allows to show the boot")
Expand Down
2 changes: 1 addition & 1 deletion pkg/commands/create_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func TestRunCreate_realAPI(t *testing.T) {
args := CreateArgs{
Name: "unittest-create-standard",
Image: "ubuntu-wily",
CommercialType: "VC1",
CommercialType: "VC1S",
}

scopedCtx, scopedStdout, scopedStderr := getScopedCtx(ctx)
Expand Down
4 changes: 2 additions & 2 deletions pkg/commands/run_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ func ExampleRun() {
ctx := testCommandContext()
args := RunArgs{
Image: "ubuntu-trusty",
CommercialType: "VC1",
CommercialType: "VC1S",
}
Run(ctx, args)
}
Expand All @@ -23,7 +23,7 @@ func ExampleRun_complex() {
Gateway: "my-gateway",
Image: "ubuntu-trusty",
Name: "my-test-server",
CommercialType: "VC1",
CommercialType: "VC1S",
Tags: []string{"testing", "fake"},
Volumes: []string{"50G", "1G"},
}
Expand Down