Open TylerRick opened 6 years ago
Looks like this is a problem if you use docker-compose config
as the input as well, even if you listed as an array in your file.
If you have this in your file:
networks:
- default
- public
, then docker-compose config
apparently normalizes it to this:
networks:
default: null
public: null
Yea this is another one of those cases where docker-compose keeps changing (improving?) their format, and it leaves everyone chasing their tail to keep up with it.
One bigger strategy for all this might be ingesting compose's openAPI schema definitions and searching for all the fields with a schema of oneOf
, and then appropriately parsing each case
Documented here: https://docs.docker.com/compose/compose-file/#aliases
Example:
Current behavior:
Expected:
I'm guessing something like this (not 100% sure yet):