Skip to content

docs(postgres): create-db picks closest region by default, us-east-1 is the fallback#8082

Merged
nurul3101 merged 2 commits into
mainfrom
docs/create-db-region-geodetect
Jul 17, 2026
Merged

docs(postgres): create-db picks closest region by default, us-east-1 is the fallback#8082
nurul3101 merged 2 commits into
mainfrom
docs/create-db-region-geodetect

Conversation

@nurul3101

@nurul3101 nurul3101 commented Jul 17, 2026

Copy link
Copy Markdown
Member

Summary

The npx-create-db docs page claimed "The default region is us-east-1." This is stale as of create-db v1.2.1: when --region is omitted, the CLI geolocates the caller and provisions the database in the closest available region, falling back to us-east-1 only when geolocation fails.

This PR updates the sentence to describe the geo-detection behavior with us-east-1 as the fallback.

Evidence

  • packages/create-db/src/cli/commands/create.ts in prisma/create-db:
    let region: RegionId = input.region ?? "us-east-1";
    
    if (!input.region) {
      const userLocation = await detectUserLocation();
      region = getRegionClosestToLocation(userLocation) ?? region;
    }
  • A live run from ap-southeast (2026-07-17) with no --region flag provisioned in ap-southeast-1.

Scope check

Swept all docs pages mentioning create-db or us-east-1 for the same stale claim; this was the only instance. Other us-east-1 mentions are verbatim sample CLI output, explicit parameters (Management API, IaC, GitHub Actions), or a different product's default (Compute).

Summary by CodeRabbit

  • Documentation
    • Updated the CLI quick-start guide to clarify that the default database region is detected automatically, with a fallback to us-east-1.
    • Clarified that users can select a region manually with the --region option.

…is the fallback

create-db v1.2.1 geolocates the caller and provisions in the closest
available region when --region is omitted; us-east-1 is only used when
geolocation fails. Update the stale default-region claim on the
npx-create-db page accordingly.
@vercel

vercel Bot commented Jul 17, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
blog Ready Ready Preview, Comment Jul 17, 2026 12:54pm
docs Ready Ready Preview, Comment Jul 17, 2026 12:54pm
eclipse Ready Ready Preview, Comment Jul 17, 2026 12:54pm
site Ready Ready Preview, Comment Jul 17, 2026 12:54pm

Request Review

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 1c8b2275-7275-4f7f-977b-312b10865eb4

📥 Commits

Reviewing files that changed from the base of the PR and between 97ede65 and f1cf804.

📒 Files selected for processing (1)
  • apps/docs/content/docs/postgres/npx-create-db.mdx

Walkthrough

Changes

Create-db region documentation

Layer / File(s) Summary
Document automatic region selection
apps/docs/content/docs/postgres/npx-create-db.mdx
The quick-start documentation now describes approximate-location detection, closest-region provisioning, the us-east-1 fallback, and manual selection with --region.

Estimated code review effort: 1 (Trivial) | ~2 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the doc update: default region selection now uses the closest region with us-east-1 as fallback.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

🍈 Lychee Link Check Report

9 links: ✅ 4 OK | 🚫 0 errors | 🔀 1 redirects | 👻 5 excluded

✅ All links are working!


Full Statistics Table
Status Count
✅ Successful 4
🔀 Redirected 1
👻 Excluded 5
🚫 Errors 0
⛔ Unsupported 0
⏳ Timeouts 0
❓ Unknown 0

@argos-ci

argos-ci Bot commented Jul 17, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Argos notifications ↗︎

Build Status Details Updated (UTC)
default (Inspect) ✅ No changes detected - Jul 17, 2026, 1:01 PM

@nurul3101

Copy link
Copy Markdown
Member Author

@coderabbitai approve

@nurul3101 nurul3101 self-assigned this Jul 17, 2026
@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor
✅ Action performed

Comments resolved and changes approved.

@nurul3101
nurul3101 merged commit 10c2e69 into main Jul 17, 2026
18 checks passed
@nurul3101
nurul3101 deleted the docs/create-db-region-geodetect branch July 17, 2026 12:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant