# Note that this docker-compose file is only for development!
#
# studentenportal:8000  ----- studentenportal-media:/srv/www/studentenportal/media
#  ||                       \
#  ||                        ---- ./:/srv/www/studentenportal/
#  ||
# postgres ----- postgres-data:/var/lib/postgresql/data
#
version: '3.2'
services:
  postgres:
    image: postgres:9.3
    restart: always
    environment:
      POSTGRES_PASSWORD: "k9F1bbHiW4o9By1A6tvL"
      POSTGRES_USER: "studentenportal"
    networks:
        - studentenportal-dev

  studentenportal:
    image: studentenportal/dev:latest
    build:
      context: .
      dockerfile: deploy/dev/Dockerfile
      args:
          - UID=${UID-1000}
          - GID=${GID-1000}
    volumes:
      - ./:/srv/www/studentenportal
    ports:
      - 8000:8000
    environment:
      DB_HOST: "postgres"
      DB_USER: "studentenportal"
      DB_PASSWORD: "k9F1bbHiW4o9By1A6tvL"
      DJANGO_DEBUG: "True"
    networks:
      - studentenportal-dev

networks:
  studentenportal-dev:

# Note that this docker-compose file is only for development!
#
# studentenportal:8000  ----- studentenportal-media:/srv/www/studentenportal/media
#  ||                       \
#  ||                        ---- ./:/srv/www/studentenportal/
#  ||
# postgres ----- postgres-data:/var/lib/postgresql/data
#
version: '3.2'
services:
  postgres:
    image: postgres:12
    restart: always
    environment:
      POSTGRES_PASSWORD: "k9F1bbHiW4o9By1A6tvL"
      POSTGRES_USER: "studentenportal"
    networks:
        - studentenportal-dev

  studentenportal:
    image: studentenportal/dev:latest
    build:
      context: .
      dockerfile: deploy/dev/Dockerfile
      args:
          - UID=${UID-1000}
          - GID=${GID-1000}
    volumes:
      - ./:/srv/www/studentenportal
    ports:
      - 8000:8000
    environment:
      DB_HOST: "postgres"
      DB_USER: "studentenportal"
      DB_PASSWORD: "k9F1bbHiW4o9By1A6tvL"
      DJANGO_DEBUG: "True"
    networks:
      - studentenportal-dev

networks:
  studentenportal-dev:

Upgrade dev environment to postgres 12
Upgrade dev environment to postgres 12

Django 2.2 dropped support for PostgreSQL 9.3:
https://docs.djangoproject.com/en/2.2/releases/2.1/#dropped-support-for-postgresql-9-3

PostgreSQL has no LTS versions, all versions are supported for five years:
https://www.postgresql.org/support/versioning/

Support for 9.3 ended in November 2018; support for 9.4 will end very
soon (February 2020). Let's upgrade to the latest available version.
