Skip to content

Commit

Permalink
docs: update readme with screenshot, latest podman/docker commands (#187
Browse files Browse the repository at this point in the history
)
  • Loading branch information
infinitewarp authored Jul 1, 2024
1 parent 7f104aa commit 169e6be
Showing 1 changed file with 20 additions and 16 deletions.
36 changes: 20 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,33 @@

Silly web app for silly quips. :tada:

[Live Demo](https://quips.infinitewarp.com/quips/)
![quips-screenshot](https://github.com/infinitewarp/quips/assets/1472326/05e6652d-4f61-4d49-9440-99f2ad7369f8)

## Setup
Yes, the names of speakers are jumbled. :slightly_smiling_face:

### Running Locally (macOS)
[Live Demo](https://quips.infinitewarp.com/quips/)

Install and start Docker:
## Setup

brew install --cask docker
open -a Docker
### Running Locally in Podman or Docker

Alternatively, using Docker Toolbox for older CPUs that don't have VT-x and
VT-d:
Using either Podman or Docker, run the app with compose:

brew install --cask docker-toolbox
docker-machine create -d "virtualbox" mydockermachine
eval $(docker-machine env mydockermachine)
podman compose -f dev.yml up --build

Run the app with compose:
The quips app should start serving on http://127.0.0.1:8000/, but you may need to load some data.

docker-compose -f dev.yml up --build
> [!NOTE]
>
> The `dev.yml` compose file is intended only for local use, not production environments.
Loading fixture data:

docker-compose -f dev.yml run django /app/manage.py loaddata trek
podman compose -f dev.yml run django /app/manage.py loaddata trek

Creating admin user:

docker-compose -f dev.yml run django /app/manage.py createsuperuser
podman compose -f dev.yml run django /app/manage.py createsuperuser

### Importing Quips

Expand All @@ -49,10 +47,16 @@ The Quips app provides a new Django management command `importquips` to import
this particular CSV format. It has an optional argument `--purge` that removes
all existing Quips, Quotes, and Speakers before importing the file.

`importquips` usage:
Local `importquips` usage:

/app/manage.py importquips [--purge] filename.csv

If you are running in composed containers, you will need to copy the file into the container before running the `importquips` command. For example:

podman compose -f dev.yml cp ./quips.csv django:/tmp/quips.csv
podman compose -f dev.yml run django /app/manage.py importquips /tmp/quips.csv


### API Usage

You can query the API for a limited set of read-only data. Supported paths include:
Expand Down

0 comments on commit 169e6be

Please sign in to comment.