# Create (and eventually run) the two containers ## Docker ### Rest server - docker build -t wcag_resr_server . - docker run --env-file .env -p 8000:8000 --name wcag_rest_server -d wcag_rest_server ### UI - docker build -t wcag_ui . - docker run --env-file UI/.env -p 7860:7860 --name wcag_ui -d wcag_ui # For network management and env management ## method 1: Run the docker-compose (skip the runs above) docker-compose up -d ## method 2: or creating a Docker network ### Create a custom network docker network create wcag-network ### Run the backend container docker run -d \ --name wcag_rest_server \ --network wcag-network \ --env-file .env \ wcag_rest_server # Run the UI container docker run -d \ --name wcag_ui \ --network wcag-network \ -p 7860:7860 \ --env-file UI/.env \ wcag_ui # Important Notes: - Backend URL in UI: Make sure your UI is configured to connect to the backend using the container name (e.g., wcag_rest_server) not localhost when running in Docker - Port exposure: Only the UI needs -p flag to expose ports to your host machine