a crowd sourced platform to help us all learn a little bit more about the things we buy, sell, and consume every day.
start by installing docker and docker compose. the following commands will generate an environment variable file, build and start the containers, and setup and migration the database:
./script/docker-setup
docker-compose up
the container's directory where the code live is linked to the root of the code base on the host, so local changes will reflected in the container.
configuration is retrieved using acm. see
config/
directory for additional configuration options (linkedin, embedly,
monitoring, etc.). to build and run application in debug mode:
export NPM_CONFIG_PRODUCTION=false
export DEBUG=*
export PORT=3000
additional services and service providers:
export CP_COOKIE_KEY= # random string used to encript cookies
export CP_CRYPTO_AUTH_TOKEN_KEY= # random string used to encript tokens
export CP_CRYPTO_USER_EMAIL_KEY= # random string used to encript emails
export CP_ENV= # environment name/label
export CP_SESSION_KEY= # random string used to encript sessions
export CP_URL= # url cp server is accessible from
export EMAIL_SERVICE_HOST=
export EMAIL_SERVICE_PASS=
export EMAIL_SERVICE_USER=
export EMBEDLY_API_KEY=
export FACEBOOK_APP_ID=
export FILES_AVATARS_IMGUR_ALBUM_ID=
export FILES_AVATARS_IMGUR_CLIENT_ID=
export FILES_AVATARS_IMGUR_PASSWORD=
export FILES_AVATARS_IMGUR_USERNAME=
export GOOGLE_ANALYTICS_ACCOUNT_ID=
export GOOGLE_RECAPTCHA_KEY=
export GOOGLE_RECAPTCHA_SECRET=
export LINKEDIN_CLIENT_ID=
export LINKEDIN_CLIENT_SECRET=
export LOG_LEVEL # log level for winston
export ROLLBAR_TOKEN=
export TRELLO_BOARD_ID=
export TRELLO_KEY=
export TRELLO_LIST_ID=
export TRELLO_TOKEN=
for database connections, we either check for *_URL
or more specific
variables:
export DATABASE_URL=
export MONGO_URL=
export MONGO_COLLECTION=
export MONGO_HOST=
export POSTGRES_DB=
export POSTGRES_HOST=
export POSTGRES_PASSWORD=
export POSTGRES_USER=
other configuration variables you might care about:
export CP_AUTH_LOCKDOWN= # require that new users be authorized
export CP_ADMIN_EMAILS= # system admin emails, comma separated
export SERVER_JIT_COMPRESSION= # enable express to compress responses
export SERVER_VIEW_CACHING= # enable express and swig to cache views
export SERVER_ROBOTS_TXT= # allow or disallow robots
export CLIENT_DEBUG_INFO= # load the main view with debug enabled
make test
will run (most) tests. see ./test/README.md for
additional documentation. make lint
will lint the codebase.
make
will build the whole application. there are targets for specific
sections in the app (see the make file for this). also, setting a DEBUG=*
environment variable (make DEBUG=*
) will build parts of the code base in
development mode and give you things like source maps, unminified code, nicer
error messages, and that's about it.
- hosting: DigitalOcean
- postgres: Compose
- mongodb: mLab
- error tracking: Rollbar
- content extraction: embed.ly
- emails: mailgun
- Alain LOUBET for the alert icon
- Aldric Rodríguez Iborra for the ice cream icon
- Aldric Rodríguez for the doughnut icon
- Andrew Sivko for the add comment icon
- ArtWorkStar for the plus icon
- Arthur Shlain for the world icon
- Austin Condiff for the menu icon
- Brent Jackson for the loading icon
- Christopher Reyes for the megaphone icon
- Creative Stall for the pencil icon
- Danil Polshin for the pizza icon
- Edward Boatman for the camera icon
- Edward Boatman for the face icon
- Edward Boatman for the shopping cart icon
- Juan León for the dead fish icon
- Kimmi Studio for the check mark icon
- Lee Mette for the cactus icon
- Leif Michelsen for the question mark icon
- Lloyd Humphreys for the information icon
- Maciej Świerczek for the hammer icon
- Marco Galtarossa for the popsicle icon
- Michael Zenaty for the magnifying glass icon
- Nikita Kozin for the bell icon
- Rafaël Massé for the link icon
- Richard Schumann for the warning icon
- Ryzhkov Anton for the soda spill icon
- Sascha Elmers for the sheep icon
- To Uyen for the book icon
- artworkbean for the star icon