Git Product home page Git Product logo

appointment-reminders-django's Introduction

Appointment Reminders (Django)

Build Status

Use Twilio to create automatic appointment reminders for your business's clients.

Read the full tutorial here!

Quickstart

Heroku

This project is preconfigured to run on Heroku. Deploy it now:

Deploy

To start the Celery worker process, which sends the SMS reminders asynchronously, you need to change a few settings in your Heroku dashboard:

  1. After the app deploys, click the Manage app button to view this app's settings
  2. Click Edit in the top right corner of the dashboard
  3. Change the app to use Free pricing - the first option
  4. Click the toggle for the worker process, enabling it for free pricing
  5. Click Save in the top right corner

Now you're all set.

To view your app, click the ... menu in the top right corner and select Open app.

Local development

This project is built using the Django web framework. It runs on Python 2.7+ and Python 3.4+.

To run the app locally, first clone this repository and cd into its directory. Then:

  1. Create a new virtual environment:
    • If using vanilla virtualenv, run virtualenv venv and then source venv/bin/activate
    • If using virtualenvwrapper, run mkvirtualenv appointments
  2. Install the requirements with pip install -r requirements.txt
  3. Start a local PostgreSQL database and create a database called appointment_reminders
    • If on a Mac, I recommend Postgres.app. After install, open psql and run CREATE DATABASE appointment_reminders;
    • If Postgres is already installed locally, you can just run createdb appointment_reminders from a terminal
  4. Run the migrations with python manage.py migrate
  5. Optionally create a superuser so you can access the Django admin: python manage.py createsuperuser
  6. Copy the .env_example file to .env, and edit it to include your Twilio API credentials (found at https://www.twilio.com/user/account/voice)
  7. Run source .env to apply the environment variables (or even better, use autoenv)
  8. Start the development server: python manage.py runserver

This project uses Celery to asynchronously send SMS reminders to users. To start the Celery process:

  1. This project uses Redis as its task queue. Install and start Redis
  2. Start a new terminal session and activate your virtual environment
  3. Source the .env file if you're not using autoenv
  4. Start the Celery worker with the command: celery -A appointments.settings worker -l info

You can then visit the application at http://localhost:8000/.

Run the tests

You can run the tests locally through coverage:

$ coverage run manage.py test --settings=appointments.settings.test

You can then view the results with coverage report or build an HTML report with coverage html.

appointment-reminders-django's People

Contributors

atbaker avatar kwhinnery avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.