codebrag
codebrag copied to clipboard
Unknown host key bitbucket.org. RSA key fingerprint
Hello
I use codebrag to integrate with bitbucket repository. When I try install codebrag then I gets TransportException with message UnknownHostKey: bitbucket.org. RSA key fingerprint is 97:8c:1b:f2:6f:14:6b:5c:3b:ec:aa:46:46:74:7c:40
I dont know how can I resolve this problem.
Can you clone & pull from the repository when on the server, from the command line?
I use source Tree and all works fine. When I configured codebrag (set user login and password) and try install then I get error message. That's look like my local server try pull all changes from repo and it dont know key.
Well I don't know what's your local setup but you need to make sure that you can pull using the user that Codebrag is running and in that directory. Maybe you need to add the key to ~/.ssh?
This is codebrag.config
repositories { username = "bitbucketLogin" password = "bitbucketPass" }
codebrag { data-dir = "./data" repos-root = "./repos" send-anon-usage-data = true web-server-port = 8080 application-url = "http://localhost:8080"
required-reviewers-count = 1
} ...
You mean add key to my ssh agent in my local server?
Yes, can you try that? The ssh key must be available for the process to use.
I use very strange and to sukc OS (Windows). Probably I have to download something ssh agent and try add ssh key. Thank you I try and if done then I provide you answer
Ok, I'm not very familir with Windows, good luck :)
@jrura18 You could install gitbash for Windows, generate ssh key with ssh-keygen command in gitbash, copy generated public key (from ~/.ssh/id_rsa.pub file) and add it to your account on bitbucket (ssh keys section is profile settings). It should do the trick.
I will check. Dzięki :)
Same issue on linux, with a user setup to access a git repository through SSH.
git clone/fetch works perfectly from bash but I get the following error in the logs:
Caused by: com.jcraft.jsch.JSchException: UnknownHostKey: (…)
Do you use the same user to git clone and when starting Codebrag?
Yes, same user.
Also having this issue. Logs are filling with:
15:54:46.661 [codebrag-akka.actor.default-dispatcher-5] ERROR c.s.c.s.commits.CommitImportService - Cannot pull changes from upstream
org.eclipse.jgit.api.errors.TransportException: ssh://xxx.yyy.zzz: UnknownHostKey: xxx.yyy.zzz. RSA key fingerprint is <...>
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:134) ~[codebrag.jar:2.3.4]
at com.softwaremill.codebrag.repository.GitRepository.pullChangesForRepo(GitRepository.scala:33) ~[codebrag.jar:2.3.4]
at com.softwaremill.codebrag.repository.Repository$class.pullChanges(Repository.scala:26) ~[codebrag.jar:2.3.4]
at com.softwaremill.codebrag.repository.GitRepository.pullChanges(GitRepository.scala:15) ~[codebrag.jar:2.3.4]
at com.softwaremill.codebrag.service.commits.CommitImportService.importRepoCommits(CommitImportService.scala:22) ~[codebrag.jar:2.3.4]
at com.softwaremill.codebrag.service.updater.RepoUpdateActor$$anonfun$receive$1.applyOrElse(RepoUpdateActor.scala:14) [codebrag.jar:2.3.4]
at akka.actor.ActorCell.receiveMessage(ActorCell.scala:425) [codebrag.jar:2.3.4]
at akka.actor.ActorCell.invoke(ActorCell.scala:386) [codebrag.jar:2.3.4]
at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:230) [codebrag.jar:2.3.4]
at akka.dispatch.Mailbox.run(Mailbox.scala:212) [codebrag.jar:2.3.4]
at akka.dispatch.ForkJoinExecutorConfigurator$MailboxExecutionTask.exec(AbstractDispatcher.scala:506) [codebrag.jar:2.3.4]
at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260) [codebrag.jar:2.3.4]
at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339) [codebrag.jar:2.3.4]
at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979) [codebrag.jar:2.3.4]
at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107) [codebrag.jar:2.3.4]
If I stop codebrag and cd repos/my-repo & git fetch everything is ok. Accessing git through ssh with key from id_rsa.pub in ~/.ssh
I got the same issue
Cannot pull changes for repo /home/service-user/codebrag-2.3.4/repos/..... UnknownHostKey: gitlab.com. RSA key fingerprint is b6:03:0e:39:97:9e:d0:e7:24:ce:a3:77:3e:01:42:09 11:11:55.067 [codebrag-akka.actor.default-dispatcher-8] ERROR c.s.c.s.commits.CommitImportService - Cannot pull changes from upstream org.eclipse.jgit.api.errors.TransportException: [email protected]:onlinepartners/cleverrobot-v1.git: UnknownHostKey: gitlab.com. RSA key fingerprint is b6:03:0e:39:97:9e:d0:e7:24:ce:a3:77:3e:01:42:09
service-user@internal1:~/codebrag-2.3.4/repos/....$ git pull Already up-to-date.
anyone had success fixing this?