Travis sudo 被禁用 [英] Travis sudo is disabled

查看:29
本文介绍了Travis sudo 被禁用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用 apt 来安装一些测试包,但是由于 sudo 被禁用,它失败了.我在测试输出中发现以下内容:

I want to use apt to install some packages for the test, however, it fails due to that the sudo is disabled. I found the following in the test output:

Sudo, the FireFox addon, setuid and setgid have been disabled.

似乎输出来自 travic-ci 中的这一行,但在 .travis.yml 中将 paranoid_mode 设置为 false 不起作用.

It seems that the output comes from this line in travic-ci, but setting paranoid_mode to false in .travis.yml does not work.

如何启用 sudo 访问?

How to enable sudo access?

PS:我使用的是私有仓库.

PS: I am using private repo.

以下 .travis.yml 将失败,因为 sudo: must be setuid root 当运行 sudo apt-get update -qq>

The following .travis.yml will fail due to sudo: must be setuid root when running sudo apt-get update -qq

language: python
python:
  - "3.4"

before_install:
  - sudo apt-get update -qq

script:
  - nosetests

设置 sudo: true 和/或 paranoid_mode: false 不起作用.

Setting sudo: true and/or paranoid_mode: false does not work.

推荐答案

在我们基于 Docker 的架构上关闭了 Sudo 访问,这将在两种情况下使用:

Sudo access is turned off on our Docker based architecture, which will be used in two contexts:

  • 存储库选择在其 .travis.yml 文件中使用 sudo: false(另外需要在我们这边打开)
  • 关于我们的教育计划(参见http://education.travis-ci.com)立>
  • repositories opt in using sudo: false in their .travis.yml file (it additionally needs to be turned on on our side)
  • on our educational program (see http://education.travis-ci.com)

由于 LXC/Docker 层中的某些安全问题,目前无法允许在基于 Docker 的架构上运行的构建使用 sudo 访问.我们希望这会在不久的将来得到解决,但不幸的是,这个问题不是我们自己能解决的.

Builds running on our Docker based architecture currently cannot be allowed sudo access due to certain security concerns in the LXC/Docker layer. We hope this will be fixed in the near future, but unfortunately the issue is out of our own hands.

我们也在努力改进 Firefox 插件,它目前使用 sudo 本身,但不应该.一旦发生这种情况,我们将在我们的博客上发布.

We are also working on improving the Firefox addon, which currently uses sudo itself, but shouldn't. We'll post on our blog once this has happened.

这篇关于Travis sudo 被禁用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆