Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 640342

Summary: sys-apps/portage: port ignored for rsync with sync-uri = ssh://user@host:port/
Product: Portage Development Reporter: Zac Medico <zmedico>
Component: Core - ConfigurationAssignee: Portage team <dev-portage>
Status: CONFIRMED ---    
Severity: normal CC: esigra, gabriel
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 240187    

Description Zac Medico gentoo-dev 2017-12-09 03:18:37 UTC
The RsyncSync code ignores the ssh port from sync-uri here, though PORTAGE_SSH_OPTS can also be used to set the port:


try:
	self.proto, user_name, hostname, port = re.split(
		r"(rsync|ssh)://([^:/]+@)?(\[[:\da-fA-F]*\]|[^:/]*)(:[0-9]+)?",
		syncuri, maxsplit=4)[1:5]
except ValueError:
	writemsg_level("!!! sync-uri is invalid: %s\n" % syncuri,
		noiselevel=-1, level=logging.ERROR)
	return (1, False)

self.ssh_opts = self.settings.get("PORTAGE_SSH_OPTS")