compose version: "2.0"
abuckenheimer opened this issue · 1 comments
Hey folks,
Noticed an issue using a downstream project ecs-cli where libcompose fails to parse the compose file when version is set to "2.0" instead of "2". I have never been a gopher but if I had to take a stab at it it seems like the issue is a naive string comparison here: if config.Version != "2" { ...
when really one would want to check for "2" or "2.0"?
A good test might be ./libcompose-cli config | ./libcompose-cli -f - config
using any docker-compose.yml. This is essentially how I ran into the bug in the wild and is a convenient way to assert that libcompose-cli config only outputs valid compose files and can read all valid compose files.
Thanks in advance! Sorry I can't be any more help :sad: