https://github.com/dtaivpp/meta-compose
Meta-compose is a small utility for managing docker compose deployments
https://github.com/dtaivpp/meta-compose
Last synced: over 1 year ago
JSON representation
Meta-compose is a small utility for managing docker compose deployments
- Host: GitHub
- URL: https://github.com/dtaivpp/meta-compose
- Owner: dtaivpp
- License: other
- Created: 2023-04-17T18:27:49.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-04-21T15:17:57.000Z (about 3 years ago)
- Last Synced: 2025-01-08T19:58:08.409Z (over 1 year ago)
- Language: Python
- Size: 7.81 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Meta-Compose
Welcome to `meta-compose`! A utility for managing docker compose environments. Meta-compose allows you to string together docker compose files and provide arguments in a straightforward manner.
### Format:
Meta-compose relies on a compose.json file to create named compose configs. For example, the below section defines two composer environments. One is named `observability` and the other is `opensearch`.
```json
{
"observability": {},
"opensearch": {}
}
```
Inside you can specify any number of the `docker compose` standard arguments. The argument should be specified in the key and the value should be either a value as a string or a list.
```json
{
"observaibility": {
"file": [
"opensearch/docker-compose.yml",
"fluentd/docker-compose.yml"
],
"env-file": "opensearch/.env",
"platform": "linux/amd64"
}
}
```
The above config file would resolve to:
```bash
docker compose --file opensearch/docker-compose.yml \
--file fluentd/docker-compose.yml \
--platform linux/amd64
```
Any commands you provide after the composer command and enironment simply get passed to docker compose. This allows you to in a more straghtforward manner control docker compose environments.
```bash
meta-compose observaibility up -d
```
The above command would resolve to:
```bash
docker compose --file opensearch/docker-compose.yml \
--file fluentd/docker-compose.yml \
--platform linux/amd64 \
up -d
```
You may have noticed that the .env file specification isn't being passed through. That is becuase python-dotenv is ingesting the environment file and injecting it in on the fly.
### Publish notes for future me
```
git tag -a "v0.0.3-beta" -m ""
git push --tags
```