Created using django, template by dennisivy, created and modify by Laurentius Nathaniel.
you can use environment variable that defined on ./env/.env.dev
vi ./env/.env.dev
you can configure the EMAIL variable for smtp on this website
you can use docker compose to create django and postgress container
docker-compose down -v
docker-compose build
docker-compose up -d
docker-compose logs
localhost:8000
create config for django environment and secret for connecting postgres database to django.
kubectl apply -f kubernetes/configmap.yaml
kubectl apply -f kubernetes/secret.yaml
kubectl apply -f kubernetes/postgres/pv.yaml
kubectl apply -f kubernetes/postgres/pvc.yaml
kubectl apply -f kubernetes/postgres/postgres.yaml
and now, expose postgres with clusterip service
kubectl apply -f kubernetes/postgres/postgres-svc
kubectl apply -f kubernetes/django/pv.yaml
kubectl apply -f kubernetes/django/pvc.yaml
kubectl apply -f kubernetes/django/django.yaml
kubectl apply -f django-svc.yaml
And now django with posgresql already deployed on your kubernetes cluster!