2.1 Docker - Pipepito/acestream-scraper GitHub Wiki
Docker Guide
What is Docker?
Docker is a platform that uses containerization technology to package applications and their dependencies together in isolated containers. These containers are lightweight, portable units that can run consistently across different environments.
Key Docker Concepts
- Container: A lightweight, standalone executable package that includes everything needed to run an application
- Image: A read-only template used to create containers
- Dockerfile: A script with instructions for building a Docker image
- Docker Compose: A tool for defining and running multi-container applications
- Volume: Persistent data storage that exists outside the container lifecycle
Benefits of Using Docker with Acestream Scraper
- Simplified Installation: No need to worry about dependencies or system compatibility
- Consistent Environment: Works the same way on any system that supports Docker
- Built-in Services: Easily includes Acestream Engine, ZeroNet, and Acexy proxy
- Isolation: Keeps the application and its dependencies contained
- Easy Updates: Simple command to update to the latest version
- Resource Management: Controls how much system resources the application can use
Docker vs. Docker Compose
Docker
- Manages individual containers
- Best for simple deployments
- Uses CLI commands to configure containers
- Example:
docker run -p 8000:8000 pipepito/acestream-scraper:latest
Docker Compose
- Manages multi-container applications
- Configuration in a YAML file
- Easier to maintain complex setups
- Example:
docker-compose up -d
For Acestream Scraper, Docker Compose is recommended as it makes managing all configuration parameters easier.
Basic Docker Commands
Pull the Image
docker pull pipepito/acestream-scraper:latest
Run the Container
docker run -d -p 8000:8000 --name acestream-scraper pipepito/acestream-scraper:latest
View Running Containers
docker ps
View Container Logs
docker logs acestream-scraper
Stop the Container
docker stop acestream-scraper
Remove the Container
docker rm acestream-scraper
Update to Latest Version
docker pull pipepito/acestream-scraper:latest
docker stop acestream-scraper
docker rm acestream-scraper
# Run the container again with your preferred configuration
Docker Compose Commands
Start Services
docker-compose up -d
View Logs
docker-compose logs
Stop Services
docker-compose down
Update to Latest Version
docker-compose pull
docker-compose up -d
Docker Data Persistence
Acestream Scraper uses Docker volumes to persist data:
/app/config
: Configuration files including database/app/ZeroNet/data
: ZeroNet data directory (if using ZeroNet)
These volumes should be mounted to local directories to ensure your data persists when containers are updated or replaced.
Example:
docker run -d -p 8000:8000 -v "${PWD}/config:/app/config" pipepito/acestream-scraper:latest
This mounts your local ./config
directory to the container's /app/config
directory.