The first hit in a Google search for "git .netrc" is:

https://gist.github.com/1072829

... and it shows you exactly what to do.



----- Original Message -----
From: ches...@tingatech.com
To: jenkinsci-users@googlegroups.com
Cc: KEVIN FLEMING (BLOOMBERG/ 731 LEXIN)
At: Jan 28 2013 15:33:30

Kevin, 

  thanks for the reply, I am not familiar with .netrc, what should I put 
into the .netrc file ? 


Chester


On Monday, January 28, 2013 12:23:20 PM UTC-8, Kevin Fleming wrote:
>
>  You can create a .netrc file in the home directory of your Jenkins user 
> on the machine(s) where you are doing the git operations; this will allow 
> Git to perform HTTP authentication without actually prompting for a 
> username/password combination.
>
> ------------------------------
> *From:*jenkins...@googlegroups.com <javascript:>*To:*
> jenkins...@googlegroups.com <javascript:>*Date:* 1/28 14:49
> ------------------------------
>
>  Hi,  
>
>     I have the same issue with private repository. Hope someone can 
> provide a pointer.
>
>     git version 1.7.9.5
>     jenkins -- 1.500  
>     Jenkins GIT plug -- 
> 1.1.26<http://ec2-50-18-85-116.us-west-1.compute.amazonaws.com:9090/pluginManager/plugin/git/thirdPartyLicenses>
>     GitHub plugin -- not available from the "available plugins" . This is 
> available from the previous version of Jenkins (1.499)
>     ubuntu on AMS EC2 instance
>
>     I have setup the ssh keys with the proper login name (email) to the 
> git hub. And put the public ssh key  to the github SSHKey. 
>     Tested the  
>
>     ssh -T g...@github.com <javascript:> 
>
>    works and authenticated. 
>
>     in Jenkins, I selected the git as repository and put the github's 
> HTTPS URL. 
>
>     With public repository, there is no problem; but with private 
> repository, I got the following error message: 
>
>
> Failed to connect to repository : Command "git ls-remote -h 
> https://github.com/xxxx/test.git HEAD" returned status code 128:
> stdout: 
> stderr: fatal: Authentication failed
>
>
>      I tried to the same command on the command line, 
>
>       git ls-remote -h https://github.com/xxxx/test.git 
>
>     the command prompt me for the login and password, once I provides the 
> both, the commend returns me the refs results. 
>
>     I can also git clone the above project from command line. 
>
>     It looks to me that the Jenkins is complaining about the login and 
> password prompt.  
>
>     I googled around and found one way to work around the issue is to 
> ssh-agent and use ssh-add to result this. but this requires start the 
> ssh-agent ....
>      
>     
>
>     is this the only way to do this, for sure I am not the first one to 
> connect the jenkins to  github's private repository.   Please help. 
>
> thanks
> Chester
>
>
>
>
>
>
>
>
> On Sunday, September 23, 2012 6:52:02 AM UTC-7, Ramesh Ankam wrote:
>>
>> Hello Group,
>>  
>> I installed Jenkins 1.4.x on Linux/Tomcat6. We have our code base in 
>> GitHub, we are unable to get clone the workspace for public and private 
>> GitHub repositories. I receive following error when repo url is added to 
>> Git option in Source Control. Any suggestions on how to fix the problem.
>>  
>> Failed to connect to repository : Error performing command: ls-remote -h 
>> https://github.com/wakaleo/game-of-life.git HEAD
>>  
>> Thanks,
>> Ramesh Ankam
>> Loading...
>>
>  -- 
> You received this message because you are subscribed to the Google Groups 
> "Jenkins Users" group.
> To unsubscribe from this group, send email to 
> jenkinsci-use...@googlegroups.com <javascript:>.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group, send email to 
jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to