Discursus
Source code for the website.
Installation with Vagrant
- Make sure you have Vagrant, Ansible, and nfsd installed (won't work on Windows).
- Run
vagrant up
- Run
vagrant ssh
to log into the box.
Development
- To run tests, use
rspec
- To run the linter/styleguide, use
rubocop
- To start the app, run
foreman start -f Procfile.dev
Installation without Vagrant box
- Install rvm and ruby 2.3.1
- Install PostgreSQL 9.5
- Install Solr 6.3 (latest at the time of writing), create a new core, and specify path to it in config/solr.yml. Copy sunspot config files schema.xml and solrconfig.xml from config/solr and place them in /var/solr/data/<collection_name>/conf. Restart the solr service afterwards.
- Install Redis
cd
into app directory and runbundle
to install the dependencies- Create .env file in directory root and populate it with data from playbooks/roles/discursus/templates/env
- After configuring database access in config/database.yml, run
rails db:create db:schema:load db:seed
. This will create database, set up the existing schema in it, and seed the administrator user with any other required data.