Git Product home page Git Product logo

tutor-match's Introduction

TutorMatch

A web app for matching tutors with students who wish to be tutored

Usage

There are a few different ways to run the server

Docker container

To build and start the app in a Docker container listening on port 8080, run

make start-docker

This will npm install any dependencies (if node_modules is missing), compile all necessary files, build the container, and start it. This includes a MariaDB server, and it will set the DATABASE_URL environment variable automatically.

To start the app in development mode, run

make start-docker-dev

This does the same as start-docker, but it will watch Typescript files for changes, compile them and restart the server. It also makes node listen on port 9229 for debuggers (--inspect).

For more tasks, see Makefile

Local

The app can alse be ran outside of Docker. To build and run the app, run

make build
node .

There are certain environment variables that must be set for this to work

Environment

Environment variables will be loaded from a .env file in the root of the project. These will be overriden by process environment variables.

  • PORT (default: 8080) The port that the application will listen at
  • PUBLIC_URI (default: 'http://localhost:$PORT') The root URI that the application is serving from. This is used for generating URIs for links and redirects
  • GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET (required) The client settings required to access Google OAuth2 APIs
  • SESSION_SECRET (required) The secret for express-session. Should be randomly generated.
  • DATABASE_URL (required) A url specifying how to connect to the MySQL database. In the format mysql://{user}:{pass}@{host}[:{port}]/{database} If running in Docker, this will be set by the container.

tutor-match's People

Contributors

amikhalev avatar a-bainbridge avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.