mirror of
https://github.com/docker/compose.git
synced 2026-08-27 03:45:29 +00:00
Merge pull request #1301 from docker/color_fix
fix color assignment on status messages
This commit is contained in:
commit
8029db807c
6 changed files with 38 additions and 34 deletions
|
|
@ -320,11 +320,11 @@ func (p printer) run(ctx context.Context, cascadeStop bool, exitCodeFrom string,
|
|||
event := <-p.queue
|
||||
switch event.Type {
|
||||
case compose.ContainerEventAttach:
|
||||
consumer.Register(event.Service, event.Source)
|
||||
consumer.Register(event.Name, event.Source)
|
||||
count++
|
||||
case compose.ContainerEventExit:
|
||||
if !aborting {
|
||||
consumer.Status(event.Service, event.Source, fmt.Sprintf("exited with code %d", event.ExitCode))
|
||||
consumer.Status(event.Name, event.Source, fmt.Sprintf("exited with code %d", event.ExitCode))
|
||||
}
|
||||
if cascadeStop {
|
||||
if !aborting {
|
||||
|
|
@ -347,7 +347,7 @@ func (p printer) run(ctx context.Context, cascadeStop bool, exitCodeFrom string,
|
|||
}
|
||||
case compose.ContainerEventLog:
|
||||
if !aborting {
|
||||
consumer.Log(event.Service, event.Source, event.Line)
|
||||
consumer.Log(event.Name, event.Source, event.Line)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue