Skip to content

Commit 0f202fd

Browse files
committed
Ensure destination image dump happens on the correct end
Previously, the dest image dump would always happen locally, no matter which mode (push or pull) was in use.
1 parent 7a2f340 commit 0f202fd

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

docker-sync

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,15 +80,15 @@ def main():
8080
common_parent = get_common_parent(source_family,all_dest)
8181
if common_parent:
8282
print("Found common parent: %s"%common_parent[:20])
83-
print("Dumping local parent".ljust(just_size,"."), end="", flush=True)
84-
_, output = execute("docker save -o %s %s"%(file_name, common_parent))
83+
print("Dumping common parent".ljust(just_size,"."), end="", flush=True)
84+
_, output = execute("docker save -o %s %s"%(file_name, common_parent), ssh=dest)
8585
check(output)
8686
else:
8787
print("Unable to find a common parent. Importing full image.")
8888
else:
8989
print("\n--> Updating '%s':\n"%name_tag)
9090
print("Dumping dest image".ljust(just_size,"."), end="", flush=True)
91-
_, output = execute("docker save -o %s %s"%(file_name, name_tag), ssh=source)
91+
_, output = execute("docker save -o %s %s"%(file_name, name_tag), ssh=dest)
9292
check(output)
9393

9494
print("Dumping source image".ljust(just_size,"."), end="", flush=True)

0 commit comments

Comments
 (0)