Skip to content

Commit e0e8895

Browse files
droplets: Region is no longer a required value. (#1234)
1 parent 0a51211 commit e0e8895

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

commands/droplets.go

+1-2
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,7 @@ func Droplet() *Command {
7474
AddStringFlag(cmdDropletCreate, doctl.ArgUserData, "", "", "User-data to configure the Droplet on first boot")
7575
AddStringFlag(cmdDropletCreate, doctl.ArgUserDataFile, "", "", "The path to a file containing user-data to configure the Droplet on first boot")
7676
AddBoolFlag(cmdDropletCreate, doctl.ArgCommandWait, "", false, "Wait for Droplet creation to complete before returning")
77-
AddStringFlag(cmdDropletCreate, doctl.ArgRegionSlug, "", "", "A slug indicating the region where the Droplet will be created (e.g. `nyc1`). Run `doctl compute region list` for a list of valid regions.",
78-
requiredOpt())
77+
AddStringFlag(cmdDropletCreate, doctl.ArgRegionSlug, "", "", "A slug indicating the region where the Droplet will be created (e.g. `nyc1`). Run `doctl compute region list` for a list of valid regions.")
7978
AddStringFlag(cmdDropletCreate, doctl.ArgSizeSlug, "", "", "A slug indicating the size of the Droplet (e.g. `s-1vcpu-1gb`). Run `doctl compute size list` for a list of valid sizes.",
8079
requiredOpt())
8180
AddBoolFlag(cmdDropletCreate, doctl.ArgBackups, "", false, "Enables backups for the Droplet")

integration/droplet_create_test.go

-1
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,6 @@ var _ = suite("compute/droplet/create", func(t *testing.T, when spec.G, it spec.
151151
}{
152152
{desc: "missing all", err: fmt.Sprintf(baseErr, ""), args: base},
153153
{desc: "missing only name", err: fmt.Sprintf(baseErr, ""), args: append(base, []string{"--size", "test", "--region", "test", "--image", "test"}...)},
154-
{desc: "missing only region", err: fmt.Sprintf(baseErr, ".region"), args: append(base, []string{"some-name", "--size", "test", "--image", "test"}...)},
155154
{desc: "missing only size", err: fmt.Sprintf(baseErr, ".size"), args: append(base, []string{"some-name", "--image", "test", "--region", "test"}...)},
156155
{desc: "missing only image", err: fmt.Sprintf(baseErr, ".image"), args: append(base, []string{"some-name", "--size", "test", "--region", "test"}...)},
157156
}

0 commit comments

Comments
 (0)