From 15833d1896185018c343352cc1d1f38d4de83ecb Mon Sep 17 00:00:00 2001 From: Ivan Vasilov Date: Tue, 3 Dec 2024 07:15:24 +0100 Subject: [PATCH 1/2] fix(studio): Bump studio version to 20241202-71e5240 (#2937) Bump studio version --- pkg/config/constants.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/config/constants.go b/pkg/config/constants.go index da0a9bf4a..23f60f25f 100644 --- a/pkg/config/constants.go +++ b/pkg/config/constants.go @@ -10,7 +10,7 @@ const ( inbucketImage = "inbucket/inbucket:3.0.3" postgrestImage = "postgrest/postgrest:v12.2.0" pgmetaImage = "supabase/postgres-meta:v0.84.2" - studioImage = "supabase/studio:20241106-f29003e" + studioImage = "supabase/studio:20241202-71e5240" imageProxyImage = "darthsim/imgproxy:v3.8.0" edgeRuntimeImage = "supabase/edge-runtime:v1.65.3" vectorImage = "timberio/vector:0.28.1-alpine" From 06db5a562a97a2323c59f23df54322475e8450b2 Mon Sep 17 00:00:00 2001 From: Han Qiao Date: Wed, 4 Dec 2024 15:20:47 +0800 Subject: [PATCH 2/2] feat: bump cli to v2 BREAKING CHANGE: deprecate fly regions for branches (#2942) --- cmd/branches.go | 23 +++-------------------- internal/utils/api.go | 35 ----------------------------------- 2 files changed, 3 insertions(+), 55 deletions(-) diff --git a/cmd/branches.go b/cmd/branches.go index df2b48a8f..0248e7f31 100644 --- a/cmd/branches.go +++ b/cmd/branches.go @@ -4,7 +4,6 @@ import ( "context" "fmt" "os" - "sort" "github.com/go-errors/errors" "github.com/spf13/afero" @@ -29,7 +28,7 @@ var ( } branchRegion = utils.EnumFlag{ - Allowed: flyRegions(), + Allowed: awsRegions(), } persistent bool @@ -96,9 +95,8 @@ var ( string(api.BranchResponseStatusFUNCTIONSFAILED), }, } - branchName string - gitBranch string - resetOnPush bool + branchName string + gitBranch string branchUpdateCmd = &cobra.Command{ Use: "update [branch-id]", @@ -114,9 +112,6 @@ var ( if cmdFlags.Changed("git-branch") { body.GitBranch = &gitBranch } - if cmdFlags.Changed("reset-on-push") { - body.ResetOnPush = &resetOnPush - } if cmdFlags.Changed("persistent") { body.Persistent = &persistent } @@ -176,7 +171,6 @@ func init() { updateFlags := branchUpdateCmd.Flags() updateFlags.StringVar(&branchName, "name", "", "Rename the preview branch.") updateFlags.StringVar(&gitBranch, "git-branch", "", "Change the associated git branch.") - updateFlags.BoolVar(&resetOnPush, "reset-on-push", false, "Reset the preview branch on git push.") updateFlags.BoolVar(&persistent, "persistent", false, "Switch between ephemeral and persistent branch.") updateFlags.Var(&branchStatus, "status", "Override the current branch status.") branchesCmd.AddCommand(branchUpdateCmd) @@ -185,17 +179,6 @@ func init() { rootCmd.AddCommand(branchesCmd) } -func flyRegions() []string { - result := make([]string, len(utils.FlyRegions)) - i := 0 - for k := range utils.FlyRegions { - result[i] = k - i++ - } - sort.Strings(result) - return result -} - func promptBranchId(ctx context.Context, ref string) error { resp, err := utils.GetSupabase().V1ListAllBranchesWithResponse(ctx, ref) if err != nil { diff --git a/internal/utils/api.go b/internal/utils/api.go index 7dc59a088..32b199b69 100644 --- a/internal/utils/api.go +++ b/internal/utils/api.go @@ -217,41 +217,6 @@ var RegionMap = map[string]string{ "us-west-2": "West US (Oregon)", } -var FlyRegions = map[string]string{ - "ams": "Amsterdam, Netherlands", - "arn": "Stockholm, Sweden", - "bog": "Bogotá, Colombia", - "bos": "Boston, Massachusetts (US)", - "cdg": "Paris, France", - "den": "Denver, Colorado (US)", - "dfw": "Dallas, Texas (US", - "ewr": "Secaucus, NJ (US)", - "fra": "Frankfurt, Germany", - "gdl": "Guadalajara, Mexico", - "gig": "Rio de Janeiro, Brazil", - "gru": "Sao Paulo, Brazil", - "hkg": "Hong Kong, Hong Kong", - "iad": "Ashburn, Virginia (US", - "jnb": "Johannesburg, South Africa", - "lax": "Los Angeles, California (US", - "lhr": "London, United Kingdom", - "maa": "Chennai (Madras), India", - "mad": "Madrid, Spain", - "mia": "Miami, Florida (US)", - "nrt": "Tokyo, Japan", - "ord": "Chicago, Illinois (US", - "otp": "Bucharest, Romania", - "qro": "Querétaro, Mexico", - "scl": "Santiago, Chile", - "sea": "Seattle, Washington (US", - "sin": "Singapore, Singapore", - "sjc": "San Jose, California (US", - "syd": "Sydney, Australia", - "waw": "Warsaw, Poland", - "yul": "Montreal, Canada", - "yyz": "Toronto, Canada", -} - func GetSupabaseAPIHost() string { apiHost := viper.GetString("INTERNAL_API_HOST") if apiHost == "" {