gpt4 book ai didi

linux - Jenkins 构建错误

转载 作者:IT王子 更新时间:2023-10-29 00:04:52 24 4
gpt4 key购买 nike

我正在尝试设置构建命令,但遇到了这些错误。我试过设置安全配置。

访问控制:

  • Jenkins 自己的用户数据库。
  • 允许用户注册。

授权:基于矩阵。

用户组:joshis1 - 检查所有。

运行构建后。我收到以下错误。在构建脚本中,我只是想复制一个文件。

失败的控制台输出

Started by user shreyas joshi
Building in workspace /var/lib/jenkins/workspace/Tungsten-Build
[Tungsten-Build] $ /bin/sh /tmp/hudson1841543545003586844.sh
November26
November26
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
sudo: sorry, you must have a tty to run sudo
Build step 'Execute shell' marked build as failure
Finished: FAILURE

最佳答案

我得到了这个问题的答案。

visudo

添加以下行:

<jenkins_user_id that u are using> ALL=(ALL)       NOPASSWD: ALL

注释此行:

#Defaults    requiretty

关于linux - Jenkins 构建错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20216900/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com