[英]toxresult_upload permission in devpi index
I am using the Python devpi server, and when I create an index, it adds a default a setting acl_toxresult_upload=:ANONYMOUS:
, but I cannot find out what it means. 我正在使用Python devpi服务器,并且在创建索引时,它会添加默认设置
acl_toxresult_upload=:ANONYMOUS:
但我无法确定它的含义。
When I view the index in the web interface, it shows: 当我在Web界面中查看索引时,它显示:
permissions
toxresult_upload
Special: ANONYMOUS
upload
Users: my-user
I googled it, but could not find any explanation of what it means. 我用谷歌搜索,但找不到任何解释。 The only thing I could find was a python test that indicates it has something to do with uploading tests, but I'm not sure what that means regarding a Pypi index.
我唯一能找到的是一个python测试 ,它表明它与上传测试有关,但是我不确定这对Pypi索引意味着什么。
# anonymous may upload tests
assert with_user(permissionrequest, None).has_permission(
'toxresult_upload', StageACL(stage, False))
devpi
supports running tests for an uploaded package with tox
on the client side. devpi
支持在客户端使用tox
对上传的软件包运行测试。 The process is roughly the following: 该过程大致如下:
python setup.py sdist
). python setup.py sdist
)。 For tests to work, the distribution must include the test scripts and the tox.ini
config. tox.ini
配置。 upload the dist to devpi
, eg 将dist上传到
devpi
,例如
devpi upload --index hoefling/dev dist/mypkg-0.1.tar.gz
run the tests via 通过运行测试
devpi test --index hoefling/dev mypkg
This will download the dist from the specified index and start the test run as configured in tox.ini
. 这将从指定的索引下载dist并按照
tox.ini
配置开始测试运行。
devpi-client
will upload the test results to the server so they can be viewed anytime via the web UI: devpi-client
会将测试结果上传到服务器,以便可以通过Web UI随时查看它们: tests
link, you will land on the page showing the test run overview: tests
链接时,您将进入显示测试运行概述的页面: By clicking on the links referring to the separate test runs, you can inspect the test run logs in details.
通过单击引用单独测试运行的链接,可以详细检查测试运行日志。
Now, acl_toxresult_upload
, similar to acl_upload
, is the list of users that are allowed to upload test results to that index. 现在,
acl_toxresult_upload
,类似acl_upload
,是被允许的测试结果上传到该索引的用户列表。 acl_toxresult_upload=:ANONYMOUS:
means that anyone can run devpi test --index your_index yourpkg
and upload the test results. acl_toxresult_upload=:ANONYMOUS:
意味着任何人都可以运行devpi test --index your_index yourpkg
并上传测试结果。 If you want to restrict the access, do it the same way you restrict the package upload access: 如果要限制访问,请按照限制程序包上载访问的相同方法进行操作:
$ devpi index your_index acl_toxresult_upload=me,admin,ci-bot
Docs: devpi test: testing an uploaded package . 文件: devpi测试:测试上传的套件 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.