A web-based interface for managing Docker containers and docker-compose configurations.
-
View all Docker containers (running and stopped)
-
Start, stop, restart, and delete containers
-
Real-time container logs viewing
-
Container inspection with detailed information
-
Container resource usage stats (CPU, memory)
-
Edit and apply docker-compose.yml directly from the web interface
-
Sort containers by:
Name (alphabetically) CPU usage (high to low) Memory usage (high to low) Uptime (high to low)
-
Filter containers by:
Status (running/stopped) Text search (matches container name, image, or compose file
Compose File Management
Compose File Editor: Edit docker-compose files directly in the web interface Auto-discovery: Automatically finds compose files in configured directories Apply Changes: Apply edited compose files directly from the interface
Environment Variables Management
Extract to Clipboard: Extract environment variables from compose files to clipboard
Easily extract variables from existing compose files Use the extracted variables to create .env files
Env Files Tab: View and edit .env files
Scan for existing .env files Create new .env files Edit and save existing .env files
Performance Optimizations
Caching: Improved responsiveness with intelligent caching Background Processing: Statistics update in the background without blocking the UI Efficient Filtering: In-memory filtering for fast response times
Using Environment Variables
Extracting Variables from Compose Files:
Select a compose file in the Compose Editor tab Click "Extract Env to Clipboard" Variables will be copied to clipboard and also displayed in the Env Files tab
Creating/Editing .env Files:
Go to the Env Files tab Click "Scan for .env Files" to find existing files Select an existing file or create a new one Edit the content and click "Save .env File"
Using .env Files with Compose:
To use an .env file with a compose file, you need to either:
Place the .env file in the same directory as your compose file Add env_file: .env to your compose file Or use the --env-file flag with docker-compose
- Docker Engine installed and running
- Python 3.7+
- Access to Docker socket
- Flask and docker Python packages (see requirements.txt)
The easiest way to use this application is to add it directly to your existing docker-compose.yml file:
If you manage containers with multiple docker-compose files in different directories:
composr:
image: vansmak/composr:latest
container_name: composr
ports:
- "5003:5003"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /path/to/your/project:/app/projectname
- /different/path/to/anotherproject:/app/projectname2 # optional
environment:
- COMPOSE_DIR=/app/compose_files
- EXTRA_COMPOSE_DIRS=/app/projectname2:/app/projectname3:/app/projectname4 #optional
restart: unless-stoppedThen run:
docker compose up -dAccess the web interface at: http://localhost:5003
- Clone this repository:
git clone https://github.com/Vansmak/composr
cd composr- Install dependencies:
pip install -r requirements.txt- Configure the path to your docker-compose.yml file you want to manage in app.py:
COMPOSE_DIR = '/path/to/your/projects' #parent dirpython app.pyAccess the web interface at: http://localhost:5003
docker build -t composr .
docker compose up -ddocker-manager/
├── app.py # Flask application
├── requirements.txt # Python dependencies
├── Dockerfile # Docker configuration
├── docker-compose.yml # Compose file for the manager itself
├── templates/
│ └── index.html # Web interface
└── README.md # Documentation
The application expects a specific path to your parent Directory before your docker-compose.yml files. Make sure to update the COMPOSE_DIR variable before running.