diff --git a/.gitignore b/.gitignore index 90ba565..abb6976 100644 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,5 @@ build node_modules target -wrangler.toml .dev.vars dist diff --git a/README.md b/README.md index 1f3b991..99b3081 100644 --- a/README.md +++ b/README.md @@ -90,12 +90,15 @@ $ npm i -g wrangler Then, run `wrangler login` and follow the instructions. -2. Clone `.dev.vars` and `wrangler.toml` +1. Clone `.dev.vars` -Both example files are provided, prefixed with an underscore. -Duplicate both files and remove the underscore. +The example file is prefixed with an underscore. -3. Start postgres (and pgbouncer) +```sh +$ cp _.dev.vars .dev.vars +``` + +1. Start postgres (and pgbouncer) Run `docker compose up --wait` to start postgres and pgbouncer. Pgbouncer is used to pool connections to the database, which is required for serverless. @@ -126,7 +129,6 @@ It might be a good idea to do this in `.dev.vars` and comment out each line -- j 2. Deploy the worker ```console -$ cp _wrangler.toml wrangler.toml # copy the example wrangler.toml $ wrangler login # login to Cloudflare $ wrangler deploy # deploy the worker # for each key and value of PG_*, run the following command diff --git a/_.dev.vars b/_.dev.vars index 73b7736..8bac93b 100644 --- a/_.dev.vars +++ b/_.dev.vars @@ -3,3 +3,4 @@ PG_USER = "admin" PG_PASSWORD = "securepassword" PG_HOST = "localhost" PG_DATABASE = "benchmarks" +FRONTEND_URL = "http://localhost:3000" diff --git a/_wrangler.toml b/wrangler.toml similarity index 100% rename from _wrangler.toml rename to wrangler.toml