Skip to content

An open source app for all Cornell student publications and events.

License

Notifications You must be signed in to change notification settings

cuappdev/volume-backend

Repository files navigation

volume-backend

An open-sourced backend for Volume, a news aggregator for Cornell's publications and magazines. Made by Cornell AppDev.

Tech stack:

  1. Typescript/Node.js
  2. MongoDB
  3. GraphQL

Installation

To run this project, you must have Node.js and Typescript installed on your machine.

Clone the project with

git clone https://github.com/cuappdev/volume-backend.git

After cloning the project cd into the new directory run

git config core.hooksPath .github/hooks

and install dependencies with

npm install

We use direnv to keep track of environment variables. Install direnv to your machine. In order to allow direnv to load environment variables, it needs to be able to hook into your shell. If using ZSH, for example, you should add the following line to the end of your ~/.zshrc file: eval "$(direnv hook zsh)"

You can find the full list of direnv hook commands here

Then, to start the project, run the following terminal commands direnv allow

npm run start

Setting up the database

Make sure MongoDB is installed. See installation guide.

To run MongoDB on a MacOS device, run

brew services start [email protected] (6.0 may be outdated, check website for updated version).

and connect MongoSH to a running instance using

mongosh

From here, you can interact with your database by typing use <db_name>.

If you are using VSCode, we recommend installing the MongoDB extension to allow you to interact with documents in your database straight through the editor. More information on this here.

Environment variables

We recommend using direnv. To set up, run the following:

cp .envrctemplate .envrc

Configuration(optional)

We recommend using ESLint and Prettier for linting/formatting. If you are using VSCode, they can be downloaded directly through the Extensions panel. Run ESLint on the codebase with npm run lint and Prettier with npm run format.

About

An open source app for all Cornell student publications and events.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published