【问题标题】:sudo: no tty present and no askpass program specified when trying to run Shell script from JENKINS AWS instancesudo:尝试从 JENKINS AWS 实例运行 Shell 脚本时不存在 tty 且未指定 askpass 程序
【发布时间】:2020-06-01 23:07:50
【问题描述】:

我正在尝试在 AWS Ubuntu 实例中使用我的 Jenkins 中的 shell 脚本运行一个基本的 docker 命令。 当我试图像这样运行时: sudo docker build mavendocker:1.0.0 . 我收到以下错误:

我尝试更改以下 visudo: How to fix 'sudo: no tty present and no askpass program specified' error? 但它搞砸了我的 AWS Ubuntu 实例的 visudo 文件。

还有其他方法可以执行我的 Jenkins 工作吗?

【问题讨论】:

    标签: jenkins amazon-ec2


    【解决方案1】: