sleepepi / patstrial.org

Website for the PATS Trial
MIT License
0 stars 0 forks source link

patstrial.org

Build Status Code Climate

PATS Trial Website. Using Rails 6.0+ and Ruby 2.6+.

Installation

Prerequisites Install Guide: Instructions for installing prerequisites like Ruby, Git, JavaScript compiler, etc.

Once you have the prerequisites in place, you can proceed to install bundler which will handle most of the remaining dependencies.

gem install bundler

This readme assumes the following installation directory: /var/www/patstrial.org

cd /var/www

git clone https://github.com/sleepepi/patstrial.org.git

cd patstrial.org

bundle install

Install default configuration files for database connection, email server connection, server url, and application name.

ruby lib/initial_setup.rb

rails db:migrate RAILS_ENV=production

rails assets:precompile RAILS_ENV=production

Run Rails Server (or use Apache or nginx)

rails s -p80

Open a browser and go to: http://localhost

All done!

Setting up cron job tasks

Edit cron jobs sudo crontab -e to run the task lib/tasks/reports.rake

SHELL=/bin/bash
*/5 * * * * source /etc/profile.d/rvm.sh && cd /var/www/patstrial.org && rvm 2.6.3 && rails reports:refresh RAILS_ENV=production

Contributing to PATS Trial website

License

PATS Trial is released under the MIT License.