adrienpoly / covid

Covid-19 patients' self-monitoring at home via forms sent by SMS

Home Page:https://www.youtube.com/watch?v=wwDJNR6SKmI

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Covid

Covid is a web application which aims to facilitate covid-19 patients' self-monitoring at home via forms sent by SMS.

Demo : video

Main configuration

Installation

It's a Rails v6.0 application which runs on Ruby v2.6+.

It requires a limited number of dependencies to run locally:

  • PostgreSQL (v10.4+)
  • Redis (Sidekiq)
  • Headless Chrome (integration specs)
  • NodeJS v12 (LTS)

The best way to install them is to use Homebrew:

brew update
brew install rbenv ruby-build postgresql redis
brew cask install chromedriver

Ruby

rbenv install 2.6.5
gem install bundler

Git

git clone git@github.com:lifen-labs/covid.git && cd covid
bundle exec install && yarn install
bundle exec rails db:setup

Environment variables

cp .env.example .env
Twilio

We use Twilio's API to send SMS:

  • TWILIO_ACCOUNT_ID (required)
  • TWILIO_AUTH_TOKEN (required)
  • TWILIO_PHONE_NUMBER (required)

How to create a text messaging account with Twilio ?

Slack

We use Slack to monitor failed SMS:

  • SLACK_HOOK_URL (optional)

Starting a local server

heroku local

Then visit http://localhost:5000/admin/ with the seeds credentials: admin@example.com / password.

Specs

bundle exec rspec spec/

or

bundle exec guard

Deployment

The fastest way to deploy covid is using Heroku:

Deploy

⚠️ Disclaimer Heroku might not be suitable to host healthcare datas in your country. We are providing this deploy link on Heroku because we think it's the easiest way to deploy a web application ;) ⚠️

Data structure

Once signed in to the app via login/password, an AdminUser can:

  • manage a CommandCenter : the app can be deployed once and used in multiple locations (TODO: add an authorisation framework like Pundit to manage access levels)
  • onboard a Patient
  • manually create a StandardSurvey; otherwise, an automated process creates one every 24 hours.

When a StandardSurvey is created, an SMS is sent with a secret temporary link. The Patient can then fill the form directly on his phone. Once the StandardSurvey is submitted, the app sets the operational status :

  • green : all good
  • yellow : default status, still all good
  • orange : a healthcare professional needs to check the survey results
  • red : a healthcare professional needs to call the patient

Both orange and red statuses require an action from the AdminUser. Each action has to be recorded through a mandatory comment within the app.

Contributing

Find details for contributing in the contribution guide.

Maintainers

License

Covid is licensed under the GNU Affero General Public License. See the included LICENSE file for details.

About

Covid-19 patients' self-monitoring at home via forms sent by SMS

https://www.youtube.com/watch?v=wwDJNR6SKmI

License:GNU Affero General Public License v3.0


Languages

Language:Ruby 90.5%Language:HTML 7.1%Language:JavaScript 1.9%Language:CSS 0.4%