diff --git a/README.md b/README.md new file mode 100644 index 0000000..04211d1 --- /dev/null +++ b/README.md @@ -0,0 +1,19 @@ +# Learn Request Queue +An app to manage requests for music performance streamers to learn new songs. + +## Bootstrapping a Development Environment + +1. Populate .env with: + + URL_PREFIX=http://localhost + + PGHOST=db + PGDATABASE=postgres + PGUSER=postgres + + TWITCH_CLIENTID=Client ID from dev.twitch.tv + TWITCH_SECRET=Client Secret from dev.twitch.tv + SESSION_SECRET=Randomly generated secret + +2. `docker-compose up` (optionally with `-d`) +3. `docker exec -i learn-request-queue-db /usr/bin/psql -U postgres < db/testdata.sql` diff --git a/db/testdata.sql b/db/testdata.sql new file mode 100644 index 0000000..64d53e9 --- /dev/null +++ b/db/testdata.sql @@ -0,0 +1,5 @@ +INSERT INTO requests (url,requester,score,state) VALUES + ('https://www.youtube.com/watch?v=dQw4w9WgXcQ','virtualdxs',0,'Rejected'), + ('https://www.youtube.com/watch?v=C5oeWHngDS4','virtualdxs',500,'Requested'), + ('https://www.youtube.com/watch?v=vXaJGBLRA_o','virtualdxs',0,'Requested'); + diff --git a/docker-compose.yml b/docker-compose.yml index 1e83076..94cae42 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -7,6 +7,8 @@ services: - db volumes: - .:/home/app + ports: + - "80:3000" env_file: .env db: container_name: learn-request-queue-db