Files
katenary/examples/ghost/docker-compose.yaml
Patrice Ferlet 418a0a8029 Use compose-go + improvements (#9)
Use compose-go https://github.com/compose-spec/compose-go  to make Katenary parsing compose file the official way.
Add labels:
- `volume-from` (with `same-pod`) to avoid volume repetition
- `ignore` to ignore a service
- `mapenv` (replaces the `env-to-service`) to map environment to helm variable (as a template string)
- `secret-vars` declares variables as secret values

More:
- Now, environment (as secret vars) are set in values.yaml
- Ingress has got annotations in values.yaml
- Probes (liveness probe) are improved
- fixed code to optimize
- many others fixes about path, bad volume check, refactorisation, tests...
2022-05-08 09:55:25 +02:00

31 lines
749 B
YAML

version: "3"
services:
blog:
image: ghost
environment:
# this is OK for local test, but not with Helm
# because the URL depends on Ingress
url: http://ghost.example.localhost
labels:
katenary.io/ports: 2368
katenary.io/ingress: 2368
# ... so we declare that "url" is actually
# the ingress host
katenary.io/mapenv: |
url: http://{{ .Values.blog.ingress.host }}
proxy:
# A simple proxy for localhost
image: quay.io/pathwae/proxy
environment:
CONFIG: |
ghost.example.localhost:
to: http://blog:2368
ports:
- 80:80
labels:
# we don't want this in Helm because we will use
# an ingress
katenary.io/ignore: true