首页 > 解决方案 > 通过 ssh jenkins 执行 aws 命令的问题

问题描述

早上好你好吗?

我在我的詹金斯中通过 ssh 执行一次执行有问题。

詹金斯问题

之前出现的那些字符并没有出现,我们也没有在节点中改变任何东西..

我们使用的代码是:

    withCredentials([usernamePassword(credentialsId: 'id', passwordVariable: 'pass', usernameVariable: 'user')]) {
        
                                def remote = [:]
                                remote.name = 'id_nme'
                                remote.host = 'ip_node'
                                remote.user = user
                                remote.password = pass
                                remote.allowAnyHosts = true
                                remote.timeoutSec = 300
        
        sshCommand remote: remote, command: "aws autoscaling describe-auto-scaling-groups --auto-scaling-group-name [name_asg]"

}

启动命令时,作业被卡住并且没有进展。

标签: jsonjenkinsgroovyssh

解决方案


推荐阅读