zkt25/z1
2025-03-19 11:50:19 +01:00
..
__pycache__ new 2025-03-18 12:53:39 +01:00
templates new 2025-03-18 12:53:39 +01:00
app.py new 2025-03-18 12:53:39 +01:00
docker-compose.postgres.yml new 2025-03-18 12:53:39 +01:00
docker-compose.yml new 2025-03-18 12:53:39 +01:00
Dockerfile new 2025-03-18 12:53:39 +01:00
LICENSE new 2025-03-18 12:53:39 +01:00
manage.py new 2025-03-18 12:53:39 +01:00
prepare-app.sh prepare added 2025-03-19 11:04:36 +01:00
Procfile new 2025-03-18 12:53:39 +01:00
README.md update README 2025-03-19 11:50:19 +01:00
remove-app.sh remove app 2025-03-19 11:44:50 +01:00
requirements.txt new 2025-03-18 12:53:39 +01:00
runtime.txt new 2025-03-18 12:53:39 +01:00
start.app.sh update 2025-03-19 11:41:44 +01:00
stop.app.sh remove app 2025-03-19 11:44:50 +01:00

Introduction

The project contains Python's Django base app, and Postgres database. The Django version 3.12 and the postgres is created from the latest image which is 14.2 at the moment. The Postgres data in mapped to a volume in docker names dbdata

We have 4 scripts that runs the starts and deleteds the complete process.

Prepare script

We get the postgres image from the docker hub repository. After that we build our Django project image.

Start script

This script uses the docker compose up company to start all the container services in docker compose.

stop script

This script stop all the container services that are mentioned within the docker compose yaml file.

remove script

This script removes all the containers, volumes, network, and images created and utilized by the docker compose script. We are passing additional flag which does the following.

  1. -v this removes all the volumes utilised with the docker compose script.
  2. --remove-orphans this flag Remove containers for services not defined in the Compose file.
  3. --rmi all this removes all the images that were created by the docker compose file