Introduction
amir20/dozzle is a small, lightweight application that provides real-time logging and monitoring for Docker containers in the browser. It’s designed to be easy to use and requires no additional configuration. With dozzle, you can capture live logs from your containers, search using intelligent fuzzy search or regular expressions, and even use SQL queries to analyze logs inside your browser. This application is perfect for quickly diagnosing issues with your Docker containers. Uses and Benefits
Primary Use Cases
- Real-time logging and monitoring for Docker containers
- Supports Docker services, allowing you to monitor logs from multiple nodes in a single interface
- Suitable for live monitoring of container logs only (does not store log files)
Benefits
- Intelligent fuzzy search for container names
- Search logs using regex, SQL queries, or simple string matching
- Small memory footprint and fast performance
- Live stats with memory and CPU usage monitoring
- Multi-user authentication with support for proxy forward authorization
- Swarm mode support
- Agent mode for monitoring multiple Docker hosts
Key Features
- Real-time logging and monitoring
- Search capabilities using regex, SQL queries, or simple string matching
- Support for Docker services and swarm mode
- Multi-user authentication and agent mode for remote host monitoring
Docker Setup
Quick Start Guide for amir20/dozzle
Dozzle is a lightweight application with a web-based interface to monitor Docker logs. It doesn’t store any log files and is ideal for live monitoring of container logs.
Prerequisites:
- Install Docker on your system.
- Have basic knowledge of Docker commands.
Step 1: Pull the Dozzle Image
Pull the latest release of the amir20/dozzle image using Docker pull command:
docker pull amir20/dozzle:latest
Step 2: Run Dozzle
Run Dozzle with Docker run command, mounting the Docker Unix socket and exposing port 8080:
docker run --name dozzle -d --volume=/var/run/docker.sock:/var/run/docker.sock -p 8080:8080 amir20/dozzle:latest
Step 3: Access Dozzle Interface
Access the Dozzle interface by navigating to http://localhost:8080/
in your browser.
Troubleshooting Common Issues
- Authentication: For authentication, refer to Dozzle’s documentation.
- Remote Hosts: To connect multiple Docker hosts using agent mode, use the
agent
flag with Docker run command:
docker run -v /var/run/docker.sock:/var/run/docker.sock -p 7007:7007 amir20/dozzle:latest agent
Advanced Configuration and Options
Refer to Dozzle’s documentation for detailed configuration options, environment variables, and advanced usage. Security Essentials for amir20/dozzle in Docker
To ensure the secure operation of amir20/dozzle in your Docker environment, follow these essential security measures:
1. Authentication and Authorization
- Use file-based authentication or forward proxy like Authelia to restrict access to Dozzle.
- Configure authentication providers using environment variables (
DOZZLE_AUTH_PROVIDER
,DOZZLE_AUTH_HEADER_USER
, etc.) as outlined in the documentation.
2. Network Security
- Expose Dozzle only on a secure port (e.g., HTTPS) and use SSL/TLS certificates to encrypt communication between clients and servers.
- Use Docker’s built-in networking features, such as Docker Compose networks or Swarm mode, to isolate containers and prevent unauthorized access.
3. Data Protection
- Ensure that sensitive data, such as authentication credentials and user configurations, are properly encrypted and stored securely within Dozzle.
- Regularly review and update dependencies to prevent vulnerabilities in the application.
4. Access Control
- Limit access to Dozzle based on user roles or permissions using configuration options like
DOZZLE_ENABLE_ACTIONS
or environment variables. - Monitor and audit access to Dozzle using Docker’s built-in logging and monitoring features.
By following these security essentials, you can help ensure the secure operation of amir20/dozzle in your Docker environment.