Skip to content

chore: rename postgres-new folder to web #144

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Dec 3, 2024
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
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ How is this possible? [PGlite](https://pglite.dev/), a WASM version of Postgres

This is a monorepo split into the following projects:

- [Web](./apps/postgres-new/): The primary web app built with Next.js
- [Web](./apps/web/): The primary web app built with Next.js
- [Browser proxy](./apps/browser-proxy/): Proxies Postgres TCP connections back to the browser using [pg-gateway](https://github.com/supabase-community/pg-gateway) and Web Sockets
- [Deploy worker](./apps/deploy-worker/): Deploys in-browser databases to database platforms (currently Supabase is supported)

Expand All @@ -41,33 +41,33 @@ From the monorepo root:
```shell
npx supabase start
```
3. Store local Supabase URL/anon key in `./apps/postgres-new/.env.local`:
3. Store local Supabase URL/anon key in `./apps/web/.env.local`:
```shell
npx supabase status -o env \
--override-name api.url=NEXT_PUBLIC_SUPABASE_URL \
--override-name auth.anon_key=NEXT_PUBLIC_SUPABASE_ANON_KEY |
grep NEXT_PUBLIC >> ./apps/postgres-new/.env.local
grep NEXT_PUBLIC >> ./apps/web/.env.local
```
4. Create an [OpenAI API key](https://platform.openai.com/api-keys) and save to `./apps/postgres-new/.env.local`:
4. Create an [OpenAI API key](https://platform.openai.com/api-keys) and save to `./apps/web/.env.local`:
```shell
echo 'OPENAI_API_KEY="<openai-api-key>"' >> ./apps/postgres-new/.env.local
echo 'OPENAI_API_KEY="<openai-api-key>"' >> ./apps/web/.env.local
```
5. Store local KV (Redis) vars. Use these exact values:

```shell
echo 'KV_REST_API_URL="http://localhost:8080"' >> ./apps/postgres-new/.env.local
echo 'KV_REST_API_TOKEN="local_token"' >> ./apps/postgres-new/.env.local
echo 'KV_REST_API_URL="http://localhost:8080"' >> ./apps/web/.env.local
echo 'KV_REST_API_TOKEN="local_token"' >> ./apps/web/.env.local
```

6. Start local Redis containers (used for rate limiting). Serves an API on port 8080:

```shell
docker compose -f ./apps/postgres-new/docker-compose.yml up -d
docker compose -f ./apps/web/docker-compose.yml up -d
```

7. Fill in the remaining variables for each app as seen in:

- `./apps/postgres-new/.env.example`
- `./apps/web/.env.example`
- `./apps/browser-proxy/.env.example`
- `./apps/deploy-worker/.env.example`

Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion apps/postgres-new/README.md → apps/web/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# postgres-new
# @database.build/web

In-browser Postgres sandbox with AI assistance. Built on Next.js.

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -755,7 +755,7 @@ function LiveShareOverlay(props: { databaseId: string }) {
<p>
We host a{' '}
<a
href="https://github.com/supabase-community/postgres-new/tree/main/apps/browser-proxy"
href="https://github.com/supabase-community/database-build/tree/main/apps/browser-proxy"
target="__blank"
rel="noopener noreferrer"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ function Footer() {
<div className="flex flex-row gap-1 pb-1 text-xs text-neutral-500 text-center justify-center">
<a
className="underline cursor-pointer"
href="https://github.com/supabase-community/postgres-new"
href="https://github.com/supabase-community/database-build"
target="_blank"
rel="noopener noreferrer"
>
Expand All @@ -261,7 +261,7 @@ function Footer() {
|{' '}
<a
className="underline cursor-pointer"
href="https://github.com/supabase-community/postgres-new/issues/new/choose"
href="https://github.com/supabase-community/database-build/issues/new/choose"
target="_blank"
rel="noopener noreferrer"
>
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading