소스 검색

fix #6579 cli ps --all

Signed-off-by: Seedf <[email protected]>
noname 6 년 전
부모
커밋
c2783d6f88
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      compose/cli/main.py

+ 2 - 1
compose/cli/main.py

@@ -721,7 +721,8 @@ class TopLevelCommand(object):
 
         if options['--all']:
             containers = sorted(self.project.containers(service_names=options['SERVICE'],
-                                                        one_off=OneOffFilter.include, stopped=True))
+                                                        one_off=OneOffFilter.include, stopped=True),
+                                key=attrgetter('name'))
         else:
             containers = sorted(
                 self.project.containers(service_names=options['SERVICE'], stopped=True) +