Dumb and dirty docker-compose files generator for traefik exposing
Project description
trado
TODO: FIX IT
Dumb and dirty docker-compose files generator for traefik exposing
All services described in one services.toml file and converted to more or less docker-compose compatible blocks. Top-level keys is services name, images, environment, volumes, ports is mirrored to docker-compose.
Services exposure to traefik
The most complicated part is public key, which is used to generate traefik labels.
public signature is:
public: <host>[/<path>][@port]
hostdirectly used as hostname in traefik labels. TLS with letsencrypt is enabled by default.pathis optional and used as path in traefik. New service will be exposed withhttps://host/pathbut after proxing the path will be truncated. Be careful,hostwithout path must be configured in a diffrenent service at least once.port: it's a hint for traefik to find a proper port for proxying
Notice, that default networks for all services with public defined is traefik.
Options
image: docker image nameenvs: list of environment variablesdoppler: extract list of variables from doppler
volumes: list of volumesports: list of portsrestart: restart policy, default isalwaysnetworks: list of networks. Default istraefikfor every service withpublicdefined but can be extended.labels: list of labels. For everypublicservice it's filled with traefik-specific labels.watchtower: add label to enable and disable autoupdate of service with watchtower
Example
[gitea]
image = "gitea/gitea:latest"
public = "git.rubedo.cloud @ 3000"
doppler = true
wathctower = true
volumes = ["./data:/data"]
ports = ["3000:3000", "2222:22"]
[gitea.envs]
USER_UID = 1000
USER_GID = 1000
TEST = "test"
[asdf]
image = "containous/whoami"
public = "asdf.rubedo.cloud"
restart = "unless-stopped"
[whoami2]
image = "containous/whoami"
public = "git.rubedo.cloud /test"
restart = "unless-stopped"
labels = "testlabel=true"
[blah]
image = "containous/whoami" # not exposed to traefik at all
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file trado-0.4.2.tar.gz.
File metadata
- Download URL: trado-0.4.2.tar.gz
- Upload date:
- Size: 5.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.10.0 Linux/5.13.0-28-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b47b85d1862c857576aa4128a665ec610e9d893aa768724dd2548f102e3fe976
|
|
| MD5 |
0af803c515986ea161fbfa124e0be0e4
|
|
| BLAKE2b-256 |
04fdc59951a845f582bf56ccf58501787a199ad51ac1d980fd7df24a1f5a14f3
|
File details
Details for the file trado-0.4.2-py3-none-any.whl.
File metadata
- Download URL: trado-0.4.2-py3-none-any.whl
- Upload date:
- Size: 5.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.10.0 Linux/5.13.0-28-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
feee2e952775808cf9e0ffb996bdf04961588c6b96c5cbb500ba7809da3b98fe
|
|
| MD5 |
4120123a0e6157f571b85be010317ab3
|
|
| BLAKE2b-256 |
362dd46643d3f13891ad55ed9679b8ec4e0699a92a1d7a06e451f1f20b269949
|