MicroServices - Cloud Computing Course
Main Components: Django, Docker, sqlLite
Prerequisites:
- docker
- python 3
- pip
Installation:
Using Docker:
open terminal, ChangeDirectory to this directory (oneLevelAbove core)
docker build --tag <IMAGE_NAME> .
docker run --publish 8000:8000 <IMAGE_NAME>
docker-compose build
1docker-compose up
On New Terminal Window
on the new terminal, ChangeDirectory to this directory (oneLevelAbove core)
docker ps
Will print the running docker instances. Copy the CONTAINER ID (eg 2da5215a81c6)docker exec -it <CONTAINER_ID> python manage.py makemigrations
docker exec -it <CONTAINER_ID> python manage.py migrate
docker exec -it <CONTAINER_ID> python manage.py migrate --run-syncdb
Running on VM:
- python3 -m venv venv
- source venv/bin/activate
- pip3 install requirements.txt
- python manage.py runserver
Usage:
- Use Postman to send requests
- Instructions at this directory at 'Instructions for the exercise.pdf'