| version: '3.8' # Define the version of the docker-compose | |
| services: | |
| web: # Name of the service | |
| # env_file: .env | |
| # image: python-env-web | |
| build: | |
| context: . # Context is the current directory | |
| dockerfile: Dockerfile # Name of the Dockerfile | |
| # args: | |
| # PYTHON_IMG: 3.9-alpine # Use Python 3.9 as base image | |
| ports: | |
| - "7860:7860" # Map host port to container port | |
| volumes: | |
| - .:/home/app # Bind mount the current directory to the container directory | |
| # - ./config:/home/nonroot/.config # Bind mount the current directory to the container directory | |
| # networks: | |
| # - main | |
| stdin_open: true | |
| tty: true | |
| # networks: | |
| # main: # Define a custom network | |