Comments (4)
fixed by #11604
from compose.
This is not really fixed - it works if services don't have profiles but when profiles are involved the behavior is strange:
# with my own build of what's now in main
$ docker-compose-linux-x86_64 version
Docker Compose version 5a1ba0e
# and this compose.yaml
$ cat compose.yaml
services:
s1:
profiles:
- p1
image: image
s2:
profiles:
- p2
image: image
# this shouldn't "work"
$ docker-compose-linux-x86_64 config s1
name: config
services:
s1:
profiles:
- p1
image: image
networks:
default: null
networks:
default:
name: config_default
# this definitely shouldn't work
$ docker-compose-linux-x86_64 --profile p2 config s1
name: config
services:
s1:
profiles:
- p1
image: image
networks:
default: null
networks:
default:
name: config_default
# this doesn't work, but it should
$ docker-compose-linux-x86_64 --profile '*' config s1
no such service: s1
from compose.
Compose commands, when ran with an explicit service name, automagically enable the target service even it's not active by profile.
You last example definitely demonstrates a bug
from compose.
oh uau, that's actually true - this thing is definitely a sea creature - nothing is plane/plain :D (is the name of the mascot chosen?)
from compose.
Related Issues (20)
- [BUG] `extends` with YAML merge anchors will ignore !override and !reset HOT 1
- [BUG] COMPOSE_REMOVE_ORPHANS only works as a shell variable, not in environment files
- [BUG] Sometimes Docker Compose does not attach corresponding networks to containers HOT 2
- [BUG] Channel double close panic on `Ctrl-C` during up
- [BUG] `down` does not remove oneoff containers (from `run`) HOT 1
- [BUG] `docker compose --exit-code-from` does not return correct exit code. HOT 1
- [BUG] can't add gateway to macvlan, containers have no internet access HOT 2
- Healthcheck console timer is broken.
- docker-compose重启服务时间太长,这是什么原因 HOT 9
- [BUG] 2.26.1 does not allow resources.limits.cpu to be a number HOT 2
- Make `docker compose attach` print stdout HOT 2
- [BUG] "deadlock" when mixing include and extends with a custom project directory HOT 5
- Please provide a way to disable warnings for docker compose HOT 10
- Proposal: Adding Support for Alternative Image Tags in Docker Compose HOT 1
- [BUG] Clear Line ASCII escape code at the beginning of every log line HOT 1
- [BUG] `-p` (aka `--project-name`) does not override the interpolated value of `COMPOSE_PROJECT_NAME` if `COMPOSE_PROJECT_NAME` is present in the environment or `.env` file HOT 2
- [BUG] profiles does not affect ps HOT 2
- [BUG] environment directive with unset value no longer takes precedence over env_file HOT 1
- [BUG] env_file directive in include does not affect interpolation for service env_file HOT 3
- [BUG] <title>Error: 'docker-compose up -d' Fails with KeyError: 'ContainerConfig HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from compose.