@@ -338,9 +338,14 @@ def create_common_container_engine_args(cli, target):
338338 return [str (a ) for a in args ]
339339
340340
341- def container_push (cli , push_name ):
341+ def container_push (cli , push_name , manifest = False ):
342342 """Construct and execute a command to push a container image."""
343- args = [container_engine (cli ), "push" , push_name ]
343+ eng = container_engine (cli )
344+ if manifest :
345+ args = [eng , "manifest" , "push" , "--all" ]
346+ else :
347+ args = [eng , "push" ]
348+ args .append (push_name )
344349 run (cli , args , check = True )
345350
346351
@@ -747,9 +752,13 @@ def push(cli, target):
747752 to_push .append ((target .image_name (tag = tag ), qual ))
748753 to_push .append ((push_name , QUAL_FQIN ))
749754 qmatcher = cli .push_selected_tags or QMatcher ("" )
755+ manifest = isinstance (target , TargetIndex ) # is it a manifest push?
750756 for push_name , tag_qual in to_push :
751757 if qmatcher (tag_qual ):
752- container_push (cli , push_name )
758+ logger .debug (
759+ "pushing named object: %s (manifest=%s)" , push_name , manifest
760+ )
761+ container_push (cli , push_name , manifest = manifest )
753762
754763
755764def archive (cli , target , location ):
0 commit comments