This repo contains code of Platzi Test Project
assigned by Juan Pablo Rojas. It's made with Django a Python Web Framework.
The problem to solve is the following:
Which is to create a website in Django that allows charging through Stripe a
monthly subscription of 29 USD and store in database: name and email of the buyer,
the amount paid by the user, when it paid and the ID Stripe recurrent customer.
The site should be developed using Docker, MySQL, unit testing and Stripe API.
- Install Docker
- Install Docker Compose
Run the command: ./run_dev.sh
So, the project will be running at http://localhost:8000
dev
: with the development environment (DEBUG option is enabled, and database is storage at local volumes).
mysql
: a mysql database, that share a local volume calleddata
django
: the django project container, with Python at version 3.4 and Django 1.10.2
To run unit tests of django project, run the following command: docker-compose run django ./manage.py test
To run commands that provides Django, you need to always put compose docker-run django / manage.py
before the command.
For example to create a super user command would be as follows:. compose docker-run django. /manage.py createsuperuser
Created with ❤️ by yoelfme