Reindentation and change labels

This commit is contained in:
2024-04-03 22:37:22 +02:00
parent 9a3fc6a2b4
commit 6ce52cc037

View File

@@ -83,7 +83,8 @@ services:
environment:
MYSQL_ROOT_PASSWORD: foobar
labels:
katenary.io/ports: 3306
katenary.v3/ports: |-
- 3306
```
### Declare ingresses
@@ -97,7 +98,9 @@ services:
image: ...
ports: 8080:5050
labels:
katenary.io/ingress: 5050
katenary.v3/ingress: |-
port: 5050
hostname: myapp.example.com
```
Note that the port to bind is the one used by the container, not the used locally. This is because Katenary create a service to bind the container itself.
@@ -130,7 +133,7 @@ services:
environment:
DB_HOST: database
labels:
katenary.io/mapenv: |
katenary.v3/mapenv: |-
DB_HOST: "{{ .Release.Name }}-database"
database:
@@ -138,7 +141,7 @@ services:
```
!!! Warning
This is a "multiline" label that accepts YAML or JSON content, don't forget to add a pipe char (`|`) and to indent your content
This is a "multiline" label that accepts YAML or JSON content, don't forget to add a pipe char (`|` or `|-`) and to **indent** your content
This label can be used to map others environment for any others reason. E.g. to change an informational environment variable.
@@ -150,7 +153,7 @@ services:
environment:
RUNNING: docker
labels:
katenary.io/mapenv: |
katenary.v3/mapenv: |-
RUNNING: kubernetes
```