These instructions are to install a development (not live) version of CrowdVoice app.
# Run the following commands
brew install postgres
postgres -D /usr/local/var/postgres
createdb "crowdvoice.by" # Your DB name of preference# Run the following commands
brew install redis
redis-server /usr/local/etc/redis.conf# Run the following commands
npm i -g knex
knex initOpen knexfile.js and edit it with the following example (adjust for your own setup):
development: {
client: 'postgresql',
connection: {
database: 'crowdvoice.by', // Your DB name of preference
user: 'your_user',
password: ''
},
pool: {
min: 2,
max: 10
},
migrations: {
tableName: 'knex_migrations'
}
},# Run the following commands
knex migrate:latest- Copy
config/config-example.jstoconfig/config.js(cp config/config-example.js config/config.js) - Edit
config.js- Update
databasefor your own setup, most likely the same as yourknexfile.js
- Update
# Run the following commands
brew install Caskroom/cask/xquartz
brew install homebrew/science/vips --with-webp --with-graphicsmagickAdditionally you can check the sharp module's readme for more information on the dependencies.
# Run the following commands
brew install x264 theora
brew install ffmpeg --with-theora --with-x264node bin/data_generator.js POSTSReplace POSTS with whatever amount of posts you want per voice, 10 by default. This is a time consuming operation so if you don't need posts it is recommended to not generate any posts (0).
npm i
npm i -g webpack
webpack -d
npm start