-
Notifications
You must be signed in to change notification settings - Fork 476
Setup for development
This guide was written for linux-based machines. It will also work with OSX. Deployment on Windows is untested, and the current suggestion is to run Ubuntu in a virtual machine using software such as VirtualBox.
In development mode, Mail 4 Good has a number of useful utilities:
- Hot reloading with webpack hot middleware
- The ability to use Redux Dev Tools (a browser extension that allows for redux time travel & viewing state)
- Additional debugging information on the server
Your machine should have NPM and Node >=7.4x installed. It will also need Redis and Postgres. A full guide for installing each of these is given below. Before you install any packages, ensure your package list is up to date with:
sudo apt-get update
sudo apt-get install -y npm
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt-get install -y nodejs
sudo apt-get install -y redis-server
- Clone the repository.
git clone https://github.com/freeCodeCamp/Mail-for-Good.git
.
- Change into the cloned directory. Install packages.
cd Mail-for-Good && npm install
- Set up your Google API key with this guide. There are only a few environment variables that need to be changed, these are listed below.
mv .env.example .env && nano .env
GOOGLE_CONSUMER_KEY= Put your consumer key from Google here
GOOGLE_CONSUMER_SECRET= Put your consumer secret key from Google here
ENCRYPTION_PASSWORD= Put a long random password here, you don't need to remember it yourself
Got an issue? Want to report a bug or a new feature you're thinking of? Please let us know here!