> So multiple ssh subprocesses should not be a huge issue, you could after all
> use ControlMaster and stuff to reuse the connection.

nice, I hadn't used ControlMaster before; that's useful.

> That said, it seems reasonable to create a shell script, or a Python script 
> and
> execute that on the remote from stdin.

the problem with that, or even with directly calling add-apt-repository
on the remote system, is it needs to be called under sudo, and there is
no guarantee the sudo call is passwordless on the remote system, so the
request for password (stdin/stdout) needs to be provided to the user.  I
don't see any clean way of doing that, but also piping commands or a
script into stdin for execution on the remote side, without significant
complications, or pulling in an external lib like paramiko.

> That said, it would be an entirely different code path which I think might be 
> worse
> than it maybe not working if the remote is at an older version.

Not sure how it would be worse.  Apt is quite clear on what needs to be
in place, and where, to add a new repo; place the apt source server conf
in Dir::Etc::sourceparts/d, place the apt archive's gpg key in
Dir::Etc::trustedparts/d, and place the apt archive login details (if
any) in Dir::Etc::netrcparts/d.  Is any of that incorrect, and/or will
any of that ever change?  If not, simply creating the proper files in-
place on the remote host should be all that's needed; all the logic of
figuring out the naming and content of the files takes place on the
local host.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/645404

Title:
  Support Private PPAs

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/software-properties/+bug/645404/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to