faradayio / cage

Develop and deploy complex Docker applications
http://cage.faraday.io
Apache License 2.0
307 stars 26 forks source link

`cage` sets `version: "2.4"` when merging targets into base #115

Open emk opened 2 years ago

emk commented 2 years ago

If pods/example.yml contains:

version: "2"
services: {}

And pods/targets/production/example.yml contains:

services: {}

We will output version: "2.4". This breaks kompose convert, which seems to be pretty confused about version numbers in general:

kompose convert --file exported.yml --chart --replicas\=1
FATA Version 2.4 of Docker Compose is not supported. Please use version 1, 2 or 3 

Workaround: Always use version: "2" at the top of any files in pods/targets that you'll pass to kompose.