version: "2"
services:
  data:
    image: debian
    volumes:
      - ./data/mysql/:/var/lib/mysql/
  mysql:
    image: mysql
    environment:
      MYSQL_DATABASE: ansible_dev
      MYSQL_USER: admin
      MYSQL_PASSWORD: password
      MYSQL_ROOT_PASSWORD: password
    volumes_from:
      - data
    ports:
      - "3306:3306"
    restart: always
  app:
    build: .
    command: python manage.py runserver 0.0.0.0:8000
    depends_on:
      - mysql
    links:
      - mysql:mysql
    environment:
      DB_USER: admin
      PYTHONUNBUFFERED: 1
      DB_PASSWORD: password
      DB_NAME: ansible_dev
      DB_HOST: mysql
    volumes:
      - "./src:/opt/app"
    ports:
      - "8000:8000"
    restart: always

version: "2"
services:
  data:
    image: debian
    volumes:
      - ./data/mysql/:/var/lib/mysql/
  mysql:
    image: mysql
    environment:
      MYSQL_DATABASE: ansible_dev
      MYSQL_USER: admin
      MYSQL_PASSWORD: password
      MYSQL_ROOT_PASSWORD: password
    volumes_from:
      - data
    ports:
      - "3306:3306"
    restart: always
  app:
    image: lozadaomr/ansi-admin
    command: python manage.py runserver 0.0.0.0:8000
    depends_on:
      - mysql
    links:
      - mysql:mysql
    environment:
      DB_USER: admin
      PYTHONUNBUFFERED: 1
      DB_PASSWORD: password
      DB_NAME: ansible_dev
      DB_HOST: mysql
    volumes:
      - "./src:/opt/app"
    ports:
      - "8000:8000"
    restart: always

Build app using updated container
Build app using updated container
