# IMPORTANT: Use run-containers.sh to set up the necessary environment variables.

version: "3.4"

services:
    web:
        image: asl-articles-web:$TAG
        build:
            context: web
            network: $BUILD_NETWORK
        ports:
        - $WEB_PORTNO:80
    flask:
        image: asl-articles-flask:$TAG
        build:
            context: .
            network: $BUILD_NETWORK
            args:
              ENABLE_TESTS: $ENABLE_TESTS
        ports:
        - $FLASK_PORTNO:5000
        volumes:
        - $SQLITE:/data/sqlite.db
        - $EXTERNAL_DOCS_BASEDIR:/data/docs/
        - $USER_FILES_BASEDIR:/data/user-files/
        - $AUTHOR_ALIASES:/app/asl_articles/config/author-aliases.cfg
        environment:
        - DBCONN
        - EXTERNAL_DOCS_BASEDIR
        - USER_FILES_BASEDIR
        - ASLRB_BASE_URL
