This guide explains how to run the APC web tool using Docker.
- Docker Desktop or Docker Engine installed
- Docker Compose (usually included with Docker Desktop)
From the apc directory, run:
cd apc
docker-compose up --buildThe APC Tool will be available at: http://localhost:10000
The docker-compose configuration mounts local directories as volumes, so changes to your code will be reflected in the containers. However, you may need to restart the services:
docker-compose restartFor production, modify the docker-compose.yml:
- Remove volume mounts
- Set
FLASK_ENV=production - Change
restart: unless-stoppedtorestart: always - Consider using a reverse proxy (nginx) in front
# Build production images
docker build -f docker/backend.dockerfile -t apc-tool:latest ..
# Run without volumes
docker run -d -p 10000:10000 --name apc-tool apc-tool:latest# Stop the service
docker-compose down
# View logs
docker-compose logs -f
# Rebuild without cache
docker-compose build --no-cache
# Remove containers and volumes
docker-compose down -vIf you get a port conflict error:
# Change ports in docker-compose.yml
# For example, change "10000:10000" to "10001:10000"If you encounter permission issues with mounted volumes:
# On Linux/Mac, ensure proper permissions
chmod -R 755 .If R packages fail to install, you may need to update the Dockerfile with additional system dependencies or specific package versions.
- Base Image: rocker/r-ver:4.2.0 (includes R)
- Python: 3.x (from apt)
- Key Dependencies: Flask, rpy2, R packages (jsonlite, MASS)
- Working Directory: /app
To modify R packages or Python dependencies, edit the respective Dockerfile:
- APC:
docker/backend.dockerfile - CrossTalk:
docker/crosstalk.dockerfileDockerfile: - `docker/backend