Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compose is version 3, but seems to be version 2 compatible #15

Closed
jkrauska opened this issue Oct 14, 2017 · 4 comments
Closed

compose is version 3, but seems to be version 2 compatible #15

jkrauska opened this issue Oct 14, 2017 · 4 comments

Comments

@jkrauska
Copy link

I have some older boxes with docker 1.10, which only supports compose version 2.

Current docker-compose.yml file lists the version at '3', but seems to be fully backward compatible with '2'.
https://github.com/ninech/netbox-docker/blob/master/docker-compose.yml#L1

Features between 2 and 3 are listed here.
https://docs.docker.com/compose/compose-file/compose-versioning/#version-21
I didn't see any features > 2 in use.

I'd done compose up with no issues on a 1.10 docker box and this single line change.
✅ Finished building the Docker images 'ninech/netbox:v2.2.1'

I'd like to propose that you only limit compose file version to the minimal needed to meet the parameters in use -- to ensure wider compatibility.

Single digit change.

@cimnine
Copy link
Collaborator

cimnine commented Oct 16, 2017

When I change the version to '2' and I do docker-compose pull, I get an error:

$ dc pull                                                       
ERROR: Invalid interpolation format for "image" option in service "netbox": "ninech/netbox:${BRANCH-latest}"

@rowanruseler
Copy link
Contributor

rowanruseler commented Oct 16, 2017

@cimnine You can resolve that by removing line 5:6 within docker-compose.yml, and changing image to "ninech/netbox:latest"

@cimnine
Copy link
Collaborator

cimnine commented Oct 16, 2017

This is correct, but I don't want to change the implementation as is.
The current implementation provides a simple way to define which version of Netbox to use without touching the docker-compose file. Whereas with the change you propose this would not be possible anymore.

@cimnine cimnine closed this as completed Oct 16, 2017
@cimnine
Copy link
Collaborator

cimnine commented Oct 16, 2017

I have written documentation about the use-case of the build variable: #17

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants