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...
This commit is contained in:
2022-05-08 09:55:25 +02:00
committed by GitHub
parent 165054ca53
commit 418a0a8029
41 changed files with 1696 additions and 1029 deletions

6
go.mod
View File

@@ -3,10 +3,14 @@ module katenary
go 1.16
require (
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510
github.com/compose-spec/compose-go v1.2.4
github.com/distribution/distribution/v3 v3.0.0-20220505155552-985711c1f414 // indirect
github.com/kr/pretty v0.2.0 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/spf13/cobra v1.4.0
github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb // indirect
golang.org/x/mod v0.5.1
golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6 // indirect
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b
)