mirror of
https://github.com/acedanger/shell.git
synced 2026-03-24 20:11:49 -07:00
fix: Update README and script to include all valid Docker Compose file extensions
This commit is contained in:
@@ -14,7 +14,7 @@ A Python command-line application to manage Docker containers defined in subdire
|
|||||||
- Python 3
|
- Python 3
|
||||||
- Docker and Docker Compose (plugin) installed.
|
- Docker and Docker Compose (plugin) installed.
|
||||||
- A `~/docker/` directory containing subdirectories for each of your projects.
|
- A `~/docker/` directory containing subdirectories for each of your projects.
|
||||||
- Each project subdirectory must contain a `docker-compose.yml` or `compose.yml` file.
|
- Each project subdirectory must contain a `docker-compose.yml`, `docker-compose.yaml`, `compose.yml`, or `compose.yaml` file.
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
Docker Manager Application
|
Docker Manager Application
|
||||||
|
|
||||||
This script manages Docker containers defined in subdirectories of `~/docker/`.
|
This script manages Docker containers defined in subdirectories of `~/docker/`.
|
||||||
Each subdirectory is treated as a project and must contain a `docker-compose.yml` or `compose.yml`.
|
Each subdirectory is treated as a project and must contain a `docker-compose.yml`, `docker-compose.yaml`, `compose.yml`, or `compose.yaml`.
|
||||||
|
|
||||||
Usage Examples:
|
Usage Examples:
|
||||||
1. List all running containers:
|
1. List all running containers:
|
||||||
@@ -50,7 +50,10 @@ def get_projects():
|
|||||||
|
|
||||||
for item in DOCKER_ROOT.iterdir():
|
for item in DOCKER_ROOT.iterdir():
|
||||||
if item.is_dir():
|
if item.is_dir():
|
||||||
if (item / "docker-compose.yml").exists() or (item / "compose.yml").exists():
|
if (item / "docker-compose.yml").exists() or \
|
||||||
|
(item / "docker-compose.yaml").exists() or \
|
||||||
|
(item / "compose.yml").exists() or \
|
||||||
|
(item / "compose.yaml").exists():
|
||||||
projects[item.name] = item
|
projects[item.name] = item
|
||||||
return projects
|
return projects
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user