version: '3.1'

services:
  web2py-rocket-ssl:
    build:
      context: .
      dockerfile: web2py-rocket-ssl
    container_name: web2py-rocket-ssl
    ports:
      - "443:443"
    networks:
      web2py-net:
        ipv4_address: 172.25.0.22
    volumes:
      - applications:/home/web2py/web2py/applications

  web2py-nginx:
    build:
      context: .
      dockerfile: web2py-nginx
    container_name: web2py-nginx
    networks:
      web2py-net:
        ipv4_address: 172.25.0.23

  web2py-db:
    build:
      context: .
      dockerfile: web2py-db
    container_name: web2py-db
    networks:
      web2py-net:
        ipv4_address: 172.25.0.24

  web2py-adminer:
    build:
      context: .
      dockerfile: web2py-adminer
    container_name: web2py-adminer
    ports:
      - "8080:8080"
    networks:
      web2py-net:
        ipv4_address: 172.25.0.25

networks:
  web2py-net:
    driver: bridge
    ipam:
     config:
       - subnet: 172.25.0.0/16

volumes:
  applications:
