Skip to content

Commit

Permalink
Improve setup experience with example values & readme tips
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew-Dickinson committed Aug 29, 2023
1 parent ed7cac8 commit a1e2f04
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 5 deletions.
6 changes: 3 additions & 3 deletions .env.sample
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
DB_NAME=
DB_USER=
DB_HOST=
DB_NAME=meshdb
DB_USER=admin
DB_HOST=127.0.0.1
DB_PASSWORD=
22 changes: 20 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,26 @@ For more information, [check the wiki](http://wiki.mesh.nycmesh.net/books/softwa

## Setup

```
To run a local copy from source code, first clone the package with git and create the expected
`.env` file (or otherwise configure the environment variables specified in `.env.sample` as
appropriate to your environment).
```sh
git clone https://github.com/andybaumgar/nycmesh-database

docker-compose up
cp .env.sample .env
nano .env # Fill in any missing values
```

Finally, start the application and database servers using `docker compose`
```sh
docker compose up
```

After a few minutes for image download & database setup, the development server should be
available at `127.0.0.1:8080`:
```sh
# Should return "[]" since the database is empty
curl http://127.0.0.1:8080/getMembers
```


0 comments on commit a1e2f04

Please sign in to comment.