Covid is a web application which aims to facilitate covid-19 patients' self-monitoring at home via forms sent by SMS.
Demo : video
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
rbenv install 2.6.5
gem install bundler
git clone [email protected]:lifen-labs/covid.git && cd covid
bundle exec install && yarn install
bundle exec rails db:setup
cp .env.example .env
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 ?
We use Slack to monitor failed SMS:
SLACK_HOOK_URL
(optional)
heroku local
Then visit http://localhost:5000/admin/ with the seeds credentials: [email protected]
/ password
.
bundle exec rspec spec/
or
bundle exec guard
The fastest way to deploy covid
is using Heroku:
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 goodyellow
: default status, still all goodorange
: a healthcare professional needs to check the survey resultsred
: 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.
Find details for contributing in the contribution guide.
- Etienne Depaulis (https://github.com/EtienneDepaulis)
Covid is licensed under the GNU Affero General Public License. See the included LICENSE file for details.