热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

为gitlab配置ssh运行器ssh被拒绝

如何解决《为gitlab配置ssh运行器ssh被拒绝》经验,如何解决这个问题?

我正在尝试为角度项目设置一个简单的gitlab CI

我只是在登台服务器上取得了成功。

这是/ etc / gitlab-runner中config.toml的摘录

  name = "awsTest10"
  url = "http://gitlab.XXXXXXX/ci"
  token = "XXXXXXXXXXXXXXXXXXXXX"
  executor = "ssh"
  [runners.ssh]
    user = "root"
    host = "ec2-XX-XX-XX-XX.eu-west-1.compute.amazonaws.com"
    port = "22"
    identity_file = "/root/.ssh/id_rsa"
  [runners.cache]

我用root创建了一个ssh密钥,并在gitlab部署密钥中复制了公共部分。我之前做了ssh-add。

当我使用跑步者时,我得到以下结果:

Running with gitlab-ci-multi-runner 1.11.1 (a67a225)
  on awsTest10 (e1ce142d)
Using SSH executor...
ERROR: Preparation failed: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
Will be retried in 3s ...
Using SSH executor...
ERROR: Preparation failed: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
Will be retried in 3s ...
Using SSH executor...
ERROR: Preparation failed: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
Will be retried in 3s ...
ERROR: Job failed (system failure): ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain

感谢帮助


推荐阅读
author-avatar
悲酥清风茶
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有