jenkins - 无法指向 Jenkins 主机上 ~/.ssh 中的 ssh key

标签 jenkins jenkins-plugins ssh-agent

我已经安装了 SSH 代理插件来使用 SSH 身份验证拉出 Git 存储库。我想使用位于系统文件中的 SSH key (来自 Jenkins master ~/.ssh 选项)。这是从官方插件页面截取的屏幕截图:

Screen from official plugin's page

不幸的是,我没有看到这个选项。我只能选择“直接输入”。请查看我的截图。

my screenshot

我配置错了吗?

最佳答案

这是一个相对较新的变化,在安全公告 440 中有解释:https://jenkins.io/security/advisory/2018-06-25/

SECURITY-440 / CVE-2018-1000601 SSH Credentials Plugin allowed the creation of SSH credentials with keys "From a file on Jenkins master". Credentials Binding Plugin 1.13 and newer allows binding SSH credentials to environment variables. In combination, these two features allow users with the permission to configure a job to read arbitrary files on the Jenkins master by creating an SSH credential referencing an arbitrary file on the Jenkins master, and binding it to an environment variable in a job.

SSH Credentials Plugin no longer supports SSH credentials from files on the Jenkins master file system, neither user-specified file paths nor ~/.ssh. Existing SSH credentials of these kinds are migrated to "directly entered" SSH credentials.

关于jenkins - 无法指向 Jenkins 主机上 ~/.ssh 中的 ssh key ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51119412/

相关文章:

jenkins - 为什么 Pipeline @Library() 语法中有时会有一个尾随下划线

git - hudson git https 密码,我该如何指定?

jenkins - 无法在 Jenkins 插件中加载 sidepanel.jelly

jenkins - 在Blue Ocean中使用不同的jenkinsfile路径

ssh - Ansible SSH 转发似乎不适用于 Vagrant

jenkins - SonarQube 无法到达本地主机

jenkins - 我的字符串中有一个 Jenkins 全局变量 - 如何评估它?

jenkins - 如何从作业中设置环境变量并在 Jenkins 的下一个作业中使用它?

windows - 将 VS Code 与 native Windows OpenSSH 客户端一起使用

即使存在于 ssh-agent 中,Git 也会要求提供 SSH 密码