Running with Docker¶
This guide explains how to run PDF Extract with OCR using Docker directly without Docker Compose. This approach is simpler but provides fewer features than the full stack deployment.
Prerequisites¶
- Docker installed on your system
- Basic knowledge of Docker commands
Quick Start¶
Run the container with the following command:
This will start the API service and make it available at http://localhost:8080.
Environment Variables¶
You can configure the container using environment variables:
Important environment variables:
| Variable | Description | Default |
|---|---|---|
IS_DOCKER_CONTAINER |
Required for Docker mode | true |
DATABASE_URL |
Database connection string | sqlite:///local.db |
Persistent Storage¶
To persist uploads and the database, mount volumes:
Limitations¶
When running the Docker image directly (compared to Docker Compose):
- No separate worker for background processing
- No Redis for message queuing
- Limited scalability
- Using SQLite instead of PostgreSQL by default
For production use, the Docker Compose setup is recommended.
Architecture Support¶
The Docker images are built for multiple architectures:
linux/amd64(x86_64)linux/arm64(aarch64)linux/arm/v7(armv7)
Docker will automatically pull the correct image for your system architecture.
Troubleshooting¶
If you encounter issues:
- Check the container logs:
docker logs <container-id> - Verify that the container is running:
docker ps - Ensure port
8080is not already in use on your host - Check if volumes have correct permissions
For more information, refer to the GitHub repository.