Code Monkey home page Code Monkey logo

Comments (5)

thaJeztah avatar thaJeztah commented on June 24, 2024

Yes, looks like the latest additions to the compose spec to allow specifying this as required are backward incompatible (or at least how it normalizes it) 🤔

Does it work it you use docker stack config instead of docker compose config ? Or perhaps (depending on your use-case) it would even be possible to skip the intermediate compose config

from cli.

membersound avatar membersound commented on June 24, 2024

No I need to use it like as follows, example:

docker compose -f docker-compose.base.yml docker-compose.project.yml config | docker stack deploy -c - httpd

So I cannot use stack config.

The question is, what is causes this error here? Is it the additional "required: true" element?

from cli.

thaJeztah avatar thaJeztah commented on June 24, 2024

No I need to use it like as follows, example:
docker compose -f docker-compose.base.yml docker-compose.project.yml config | docker stack deploy -c - httpd
So I cannot use stack config.

Hm, but bothdocker stack config and docker stack deploy support multiple files, so I was curious why that didn't work; https://docs.docker.com/reference/cli/docker/stack/config/#examples

The question is, what is causes this error here? Is it the additional "required: true" element?

Yes; the schema used by docker stack deploy and previous versions of compose spec accepted a string (or array of strings) for env_file; this new format changes it to an array of objects/structs({ "path": <string>, "required": <bool>})

from cli.

membersound avatar membersound commented on June 24, 2024

I don't remember the needs exactly for using docker compose config instead of docker stack config, but I think it had to do with the fact that stack config relies on some older version or syntax, because it does not implement the compose-spec.

For example, it lacks the extends feature (moby/moby#31101).

So I hope there will be a fix for `docker stack deploy' , similar to what has been done in a recent issue where also a compose change was not backwards compatible: #4859

from cli.

membersound avatar membersound commented on June 24, 2024

This is probably related to:
docker/compose#11591
docker/compose#11598
docker/compose#11604

In todays Docker 25.0.5 the issue is fixed.

But maybe you want to support the --no-interpolate mode in future?

from cli.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.