{"action":"opened","issue":{"url":"https://api.github.com/repos/ros2/build_cop/issues/115","repository_url":"https://api.github.com/repos/ros2/build_cop","labels_url":"https://api.github.com/repos/ros2/build_cop/issues/115/labels{/name}","comments_url":"https://api.github.com/repos/ros2/build_cop/issues/115/comments","events_url":"https://api.github.com/repos/ros2/build_cop/issues/115/events","html_url":"https://github.com/ros2/build_cop/issues/115","id":319078111,"number":115,"title":"icecube uses credential username after updates.","user":{"login":"nuclearsandwich","id":358882,"avatar_url":"https://avatars0.githubusercontent.com/u/358882?v=4","gravatar_id":"","url":"https://api.github.com/users/nuclearsandwich","html_url":"https://github.com/nuclearsandwich","followers_url":"https://api.github.com/users/nuclearsandwich/followers","following_url":"https://api.github.com/users/nuclearsandwich/following{/other_user}","gists_url":"https://api.github.com/users/nuclearsandwich/gists{/gist_id}","starred_url":"https://api.github.com/users/nuclearsandwich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nuclearsandwich/subscriptions","organizations_url":"https://api.github.com/users/nuclearsandwich/orgs","repos_url":"https://api.github.com/users/nuclearsandwich/repos","events_url":"https://api.github.com/users/nuclearsandwich/events{/privacy}","received_events_url":"https://api.github.com/users/nuclearsandwich/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-05-01T00:16:13Z","updated_at":"2018-05-01T00:16:13Z","closed_at":null,"author_association":"OWNER","body":"After today's updates. Running a test job on icecube was failing with ssh authentication errors. I checked the stuff from the setup notes and then generated a test key to make sure that key authentication works in general.\r\n\r\nUpon closer examination I saw that it was using a strange username when trying to authenticate with github.com:\r\ndespite the git commands specifying `git@github.com` there is an authentication failure for `ros2-buildfarm@github.com: Permission denied (publickey)`. It turns out this username comes from the credential entry in the jenkins credential store. I've created a test credential using the same key but with the git@ username and that's allowing the test job to proceed.\r\n\r\nI checked the Git 2.17 changelog for anything that would suggest this change from 2.16.2 but there was nothing that popped out. I don't have an easy way to see exactly what Jenkins is populating the environment variable with but we may need to switch the main credential username. \r\n\r\n<details><summary>Failure log</summary>\r\n\r\n```\r\n23:56:44 Building remotely on windows_icecube (test_windows) in workspace C:\\J\\workspace\\testx_ci_win\r\n23:57:06  > git rev-parse --is-inside-work-tree # timeout=10\r\n23:57:07 Fetching changes from the remote Git repository\r\n23:57:07  > git config remote.origin.url git@github.com:ros2/ci.git # timeout=10\r\n23:57:07 Fetching upstream changes from git@github.com:ros2/ci.git\r\n23:57:07  > git --version # timeout=10\r\n23:57:07 using GIT_SSH to set credentials \r\n23:57:07  > git fetch --tags --progress git@github.com:ros2/ci.git +refs/heads/*:refs/remotes/origin/*\r\n23:57:08 ERROR: Error fetching remote repo 'origin'\r\n23:57:08 hudson.plugins.git.GitException: Failed to fetch from git@github.com:ros2/ci.git\r\n23:57:08 \tat hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:862)\r\n23:57:08 \tat hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1129)\r\n23:57:08 \tat hudson.plugins.git.GitSCM.checkout(GitSCM.java:1160)\r\n23:57:08 \tat hudson.scm.SCM.checkout(SCM.java:495)\r\n23:57:08 \tat hudson.model.AbstractProject.checkout(AbstractProject.java:1202)\r\n23:57:08 \tat hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:574)\r\n23:57:08 \tat jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)\r\n23:57:08 \tat hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:499)\r\n23:57:08 \tat hudson.model.Run.execute(Run.java:1724)\r\n23:57:08 \tat hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)\r\n23:57:08 \tat hudson.model.ResourceController.execute(ResourceController.java:97)\r\n23:57:08 \tat hudson.model.Executor.run(Executor.java:429)\r\n23:57:08 Caused by: hudson.plugins.git.GitException: Command \"git fetch --tags --progress git@github.com:ros2/ci.git +refs/heads/*:refs/remotes/origin/*\" returned status code 128:\r\n23:57:08 stdout: \r\n23:57:08 stderr: ros2-buildfarm@github.com: Permission denied (publickey).\r\n23:57:08 fatal: Could not read from remote repository.\r\n23:57:08 \r\n23:57:08 Please make sure you have the correct access rights\r\n23:57:08 and the repository exists.\r\n```\r\n\r\n</details>"}}
{"actor":{"display_login":"nuclearsandwich"}}