After populating all enviroment variables, your resultant file will look something like this
# node application environment development,testing,staging,production
NODE_ENV=development
# mongodb database url
MONGODB_URI=mongodb://localhost:27017/tipoff
# mongodb database url to be used when running tests
MONGODB_URI_TEST=mongodb://localhost:27017/test-tipoff
# port number at which app will listen
# this is not required when deploying on heroku. the app will default to process.env.PORT for heroku
TIPOFF_API_PORT=5000
# secret key used to sign and validate auth token
JWT_SECRET_KEY=mysecretkey
#SendGrid API key to notify of new tips via email
NOTIFIER_API_KEY_SENDGRID=mysendgridapikey
#SendGrid From email to use when sending out email notifications
[email protected]
npm start
- In a new terminal tab or window, go to the Tipoff directory
- drill down into react-app directory
cd react-app
- Install the react application dependencies
npm install
Find the following line in tipoff/react-app/package.json
"proxy": "http://localhost:5000"
and change it to
"proxy": "http://localhost:<your_new_api_port>"
- Start the react-app Within the react-app directory, run
npm start
You can now navigate to Tipoff UI at http://localhost:3000 or your own react-app port