Skip to content

Support stacks with "include" files (and "extends", "env_file", etc) #9

Description

@starfishpatkhoo

Background

It is very useful to use include in a stack.. Sometimes we have different services managed elsewhere and we just want to include it into the current stack. One of the biggest reasons to do this is for depends_on, which only works on services within the same stack. With includes, we get separate stacks for different apps in different folders, and still able to use depends_on for a poor man's docker swarm/Kubernetes startup ordering...

Problem

Everything works mind you. Except that dockge only sees the top level of the stack, not the individual containers.

Image

Above is a screenshot of a stack using includes. Notice there are no containers within the stack.

Image

Now, the same stack but without using includes. Notice the individual containers within the stack.

Proposed Solution

It would be great if for the analysis of the docker-compose.yml, dockge would execute docker compose config and use the output from there instead of just reading the yml file directly.

Caveats

  • One should NOT expect dockge to be able to edit all the individual include, env_file, .env and extends files nor follow those paths - that's too much work for dockge, I feel.
  • If dockge wanted to view the compose stack, maybe display read-only the docker compose config output as an option

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions