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

configs.content syntax not supported despite being valid in Docker Compose 2.23.1+ #727

Open
2 tasks done
MbMa opened this issue Jan 29, 2025 · 1 comment
Open
2 tasks done
Labels
bug Something isn't working

Comments

@MbMa
Copy link

MbMa commented Jan 29, 2025

⚠️ Please verify that this bug has NOT been reported before.

  • I checked and didn't find similar issue

🛡️ Security Policy

Description

Description

When trying to use the new Docker Compose configs with inline content syntax (introduced in Docker Compose 2.23.1), Dockge validation fails with the error:
validating /opt/stacks/qdrant/compose.yml: configs.qdrant_config Additional property content is not allowed

This syntax is officially supported by Docker Compose 2.23.1+ and Docker Engine 25.0.0+ as documented here: https://docs.docker.com/compose/compose-file/07-configs/#configs-configuration-reference

Example Configuration

Here's a minimal example that triggers the error:

services:
  qdrant:
    image: qdrant/qdrant:latest
    configs:
      - source: qdrant_config
        target: /qdrant/config/production.yaml

configs:
  qdrant_config:
    content: |
      log_level: INFO

Importance

This new syntax is particularly useful for keeping simple configurations inline without needing separate files. It would be great to have support for this feature in Dockge.

👟 Reproduction steps

Steps to Reproduce

  1. Install Docker Engine ≥25.0.0 and Docker Compose ≥2.23.1
  2. Create a new stack in Dockge
  3. Create a compose.yml file with the following content:
services:
  qdrant:
    image: qdrant/qdrant:latest
    configs:
      - source: qdrant_config
        target: /qdrant/config/production.yaml

configs:
  qdrant_config:
    content: |
      log_level: INFO
  1. Try to save/update the stack in Dockge
  2. Observe the validation error

Verification

To verify this is a Dockge-specific issue:

  1. Save the same compose.yml file locally
  2. Run docker compose up from command line
  3. The compose file works correctly when run directly with Docker Compose

👀 Expected behavior

Dockge should validate this as correct syntax since it's supported by recent Docker Compose versions.

😓 Actual Behavior

Validation fails with the error message about content not being an allowed property.

Dockge Version

1.4.2

💻 Operating System and Arch

Ubuntu 20.04.6 aarch64

🌐 Browser

Firefox

🐋 Docker Version

Docker version 27.4.1, build b9d17ea, build b9d17ea / Docker Compose version v2.32.1

🟩 NodeJS Version

No response

📝 Relevant log output

@MbMa MbMa added the bug Something isn't working label Jan 29, 2025
@GorillaCoder
Copy link

GorillaCoder commented Feb 2, 2025

Ditto. Another use case: I'd like to have a pw in the config file, pulling the pw from the environment. I can do that if I generate the config inside of the containerfile, but not if I use a static file.

Looks like dockge is using docker compse 2.21 rather than 2.23. Hopefully simple to update?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants