From Newsgroup: muc.lists.freebsd.ports
------=_Part_116205_1638998967.1781778228142
Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit
Thanks all for the suggestions. I figured it out.
I needed to find out as which user this part of the Jenkins job was running and set the private key up in the right spot. Sometimes it is so simple in hindsight.
This ssh-agent step in Jenkins will be a nice addition for the future me.
Thanks and regards,
Ronald.
Van: Benjamin Jacobs <
freebsd@dev.thsi.be>
Datum: donderdag, 18 juni 2026 12:07
Aan: Ronald Klop <
ronald-lists@klop.ws>
CC:
ports@freebsd.org
Onderwerp: Re: poudriere using git+ssh and private key?
On Thu, 18 Jun 2026 11:50:01 +0200 (CEST)
Ronald Klop <ronald-lists@klop.ws> wrote:
Hi,
I'm improving my poudriere setup to get the ports tree via git+ssh.
poudriere ports -c -f "dummypool/poudriere/ports/branchX" -m git+ssh
-B "branchX" -p "test" -U ssh://ronald@<githost>/usr/ports
This works from the command line, but it all runs from Jenkins so I
don't want interactive passwords for ssh. How do I pass an ssh
private key to the git/ssh invocation?
Regards,
Ronald.
Hi,
If you have the private key registered in Jenkins' credential store,
you should be able to do that with the sshagent step, see: https://www.jenkins.io/doc/pipeline/steps/ssh-agent/
If not then you'd want to configure ssh authentication as usual, for
example by generating a key and copying its public counter part to the repository, and/or setup the ~/.ssh/config accordingly.
Best regards,
Benjamin
------=_Part_116205_1638998967.1781778228142
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
<html><head></head><body>Thanks all for the suggestions. I figured it out.<br> I needed to find out as which user this part of the Jenkins job was running and set the private key up in the right spot. Sometimes it is so simple in hindsight.<br>
This ssh-agent step in Jenkins will be a nice addition for the future me.<br>
Thanks and regards,<br>
Ronald.<br>
<p><strong>Van:</strong> Benjamin Jacobs <
freebsd@dev.thsi.be><br> <strong>Datum:</strong> donderdag, 18 juni 2026 12:07<br>
<strong>Aan:</strong> Ronald Klop <
ronald-lists@klop.ws><br> <strong>CC:</strong>
ports@freebsd.org<br>
<strong>Onderwerp:</strong> Re: poudriere using git+ssh and private key?</p>
<blockquote style="padding-right: 0px; padding-left: 5px; margin-left: 5px; border-left: #000000 2px solid; margin-right: 0px">
<div class="MessageRFC822Viewer" id="P">
<div class="TextPlainViewer" id="P.P">On Thu, 18 Jun 2026 11:50:01 +0200 (CEST)<br>
Ronald Klop <
ronald-lists@klop.ws> wrote:<br>
> Hi,<br>
><br>
> I'm improving my poudriere setup to get the ports tree via git+ssh.<br> ><br>
> poudriere ports -c -f "dummypool/poudriere/ports/branchX" -m git+ssh<br> > -B "branchX" -p "test" -U
ssh://ronald@<githost>/usr/ports<br> ><br>
> This works from the command line, but it all runs from Jenkins so I<br> > don't want interactive passwords for ssh. How do I pass an ssh<br>
> private key to the git/ssh invocation?<br>
><br>
> Regards,<br>
> Ronald.<br>
> <br>
Hi,<br>
If you have the private key registered in Jenkins' credential store,<br>
you should be able to do that with the sshagent step, see:<br>
<a href="
https://www.jenkins.io/doc/pipeline/steps/ssh-agent/">https://www.jenkins.io/doc/pipeline/steps/ssh-agent/</a><br>
If not then you'd want to configure ssh authentication as usual, for<br> example by generating a key and copying its public counter part to the<br> repository, and/or setup the ~/.ssh/config accordingly.<br>
Best regards,<br>
Benjamin</div>
<hr></div>
</blockquote>
</body></html>
------=_Part_116205_1638998967.1781778228142--
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to
news-admin@muc.de
--- Synchronet 3.22a-Linux NewsLink 1.2