Skip to content

Kheyzell/friezz

Repository files navigation

Friezz

Quizz for friends

Friezz is a fun app for making questionnaires with friends. You create quizzes, answer questions, guess your friends' answers, and see who knows who best. It's a game to get to know each other and share stories.

Table of Contents

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

Installation

In a terminal, clone the repository:

git clone https://github.com/kheyzell/Friezz.git

Running the Project

There are three ways to run the project:

Running the App in Docker Containers (easy way)

To run the entire application, including the frontend, backend, and database, in Docker containers, use the following command:

npm run docker:watch

This command will start all services and watch for changes in the code for development purposes.


Running the Database in Docker and the Client and Server Locally

If you prefer to run the database in a Docker container while running the client and server locally, follow these steps:

  1. Start the PostgreSQL database and pgAdmin in Docker containers:
npm run docker:start-db
  1. Install the necessary packages:
npm install
  1. Create a .env file in the ./apps/server folder with the following configuration:
NODE_ENV=development

DATABASE_HOST=localhost
DATABASE_PORT=5432
DATABASE_DATABASE=postgres
DATABASE_USERNAME=postgres
DATABASE_PASSWORD=letmein
DATABASE_LOGGING=true
  1. Start the client and server locally:
npm start

Running Everything Locally

To run the entire application locally, follow these steps:

  1. Download and install PostgreSQL.
  2. Create a new database for the application.
  3. Install the necessary packages:
npm install
  1. Create a .env file in the ./apps/server folder with the following configuration:
NODE_ENV=development

DATABASE_HOST=localhost
DATABASE_PORT=5432
DATABASE_DATABASE=<database name>
DATABASE_USERNAME=<username>
DATABASE_PASSWORD=<password>
DATABASE_LOGGING=true
  1. Start the application:
npm start

When the app is running:

  • The app will be available on: http://localhost:5701/
  • The server will listen on port 5000
  • The PgAdmin interface to manage the database will be available on: http://localhost:5050/
    • login using those credentials:
      • email: postgres@friezz.com
      • password: letmein
    • register the PostgreSQL server
      • right click on Servers > Register > Server...
      • in the connection tab add those information:
        • host name: database_postgres
        • port: 5432
        • username: postgres
        • password: letmein

Contribute

You can contribute multiple ways (even without technical skills):

For more details see Contribution guidelines for this project

Structure

root // Root directory. Contains many configuration files and all other folders
├── apps // Contains all the packages necessary for the app as a monorepo
|   └── client // Frontend package [React.js]
|   └── common // Shared types and functions between packages
|   └── server // Backend package [NestJS]
├── database // Database related files (contains the database schema dump)
└── docs // Documentation files

License

This project is licensed under the MIT License - see the LICENSE file for details.