From 219109aec71bbb40dc92c18f69a2d473e455f216 Mon Sep 17 00:00:00 2001 From: Phillip Jones Date: Mon, 25 Nov 2024 03:11:25 -0800 Subject: [PATCH] Added Oceania (oc) location hint as acceptable choice when creating an R2 bucket. (#7330) --- .changeset/famous-dragons-retire.md | 5 +++++ packages/wrangler/src/__tests__/r2.test.ts | 4 ++-- packages/wrangler/src/r2/constants.ts | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) create mode 100644 .changeset/famous-dragons-retire.md diff --git a/.changeset/famous-dragons-retire.md b/.changeset/famous-dragons-retire.md new file mode 100644 index 000000000000..955d467ddfe2 --- /dev/null +++ b/.changeset/famous-dragons-retire.md @@ -0,0 +1,5 @@ +--- +"wrangler": patch +--- + +Added Oceania (oc) location hint as acceptable choice when creating an R2 bucket. diff --git a/packages/wrangler/src/__tests__/r2.test.ts b/packages/wrangler/src/__tests__/r2.test.ts index 0854d8be085c..afbd9bccbb42 100644 --- a/packages/wrangler/src/__tests__/r2.test.ts +++ b/packages/wrangler/src/__tests__/r2.test.ts @@ -247,7 +247,7 @@ describe("r2", () => { -v, --version Show version number [boolean] OPTIONS - --location The optional location hint that determines geographic placement of the R2 bucket [string] [choices: \\"weur\\", \\"eeur\\", \\"apac\\", \\"wnam\\", \\"enam\\"] + --location The optional location hint that determines geographic placement of the R2 bucket [string] [choices: \\"weur\\", \\"eeur\\", \\"apac\\", \\"wnam\\", \\"enam\\", \\"oc\\"] -s, --storage-class The default storage class for objects uploaded to this bucket [string] -J, --jurisdiction The jurisdiction where the new bucket will be created [string]" `); @@ -280,7 +280,7 @@ describe("r2", () => { -v, --version Show version number [boolean] OPTIONS - --location The optional location hint that determines geographic placement of the R2 bucket [string] [choices: \\"weur\\", \\"eeur\\", \\"apac\\", \\"wnam\\", \\"enam\\"] + --location The optional location hint that determines geographic placement of the R2 bucket [string] [choices: \\"weur\\", \\"eeur\\", \\"apac\\", \\"wnam\\", \\"enam\\", \\"oc\\"] -s, --storage-class The default storage class for objects uploaded to this bucket [string] -J, --jurisdiction The jurisdiction where the new bucket will be created [string]" `); diff --git a/packages/wrangler/src/r2/constants.ts b/packages/wrangler/src/r2/constants.ts index e16674ce20e4..a5fd5447d8f6 100644 --- a/packages/wrangler/src/r2/constants.ts +++ b/packages/wrangler/src/r2/constants.ts @@ -2,4 +2,4 @@ * The maximum file size we can upload using the V4 API. */ export const MAX_UPLOAD_SIZE = 300 * 1024 * 1024; -export const LOCATION_CHOICES = ["weur", "eeur", "apac", "wnam", "enam"]; +export const LOCATION_CHOICES = ["weur", "eeur", "apac", "wnam", "enam", "oc"];