
如果你使用 DeepSeek、元宝 AI、Copilot、ChatGPT 等 AI 工具,协助配置轩辕镜像、编写 docker pull 命令、修改 Docker Compose 镜像地址、配置镜像加速、排查镜像拉取失败、分析报错日志等问题,请先让 AI 阅读并遵守轩辕镜像的规则文档。
只需在 AI 对话中先发送下面这句话即可:
请先完整阅读并严格遵守以下文档中的全部规则与要求:
https://xuanyuan.cloud/agents.md
在未充分阅读并理解该文档前,不要生成任何命令、配置、修改建议、故障排查方案或技术回答。后续所有输出都必须严格以该文档中的规范为最高优先级执行。查看 agents.md 用法指南与完整示范。国内用户首推 元宝 AI、DeepSeek 的深度思考模式,不推荐豆包 AI;Cursor 等编辑器可在对话 @ 该链接,或加入 User Rules。 若 AI 无法访问外链,可 打开说明文档 复制全文粘贴。文档会随站点更新,复制内容可能过期,建议定期检查。
https://img.shields.io/pypi/v/dco-check](https://pypi.org/project/dco-check/) https://codecov.io/gh/christophebedard/dco-check/branch/master/graph/badge.svg](https://codecov.io/gh/christophebedard/dco-check) https://img.shields.io/github/license/christophebedard/dco-check](https://github.com/christophebedard/dco-check/blob/master/LICENSE) https://img.shields.io/docker/pulls/christophebedard/dco-check?logo=docker](https://hub.docker.com/r/christophebedard/dco-check)
https://img.shields.io/github/workflow/status/christophebedard/dco-check/CI?label=CI&logo=github](https://github.com/christophebedard/dco-check) https://img.shields.io/gitlab/pipeline/christophebedard/dco-check?label=CI&logo=gitlab](https://gitlab.com/christophebedard/dco-check/commits/master) https://img.shields.io/travis/com/christophebedard/dco-check?label=CI&logo=travis](https://travis-ci.com/github/christophebedard/dco-check) https://img.shields.io/azure-devops/build/christophebedard/74e64a5d-0fe6-4759-bb97-eb77bb0d15af/1?label=CI&logo=azure%20pipelines](https://dev.azure.com/christophebedard/dco-check/_build/latest?definitionId=1&branchName=master) https://img.shields.io/appveyor/build/christophebedard/dco-check?label=CI&logo=appveyor](https://ci.appveyor.com/project/christophebedard/dco-check) https://img.shields.io/circleci/build/github/christophebedard/dco-check?label=CI&logo=circle&logoColor=white](https://circleci.com/gh/christophebedard/dco-check)
dco-check是一个简单的DCO检查脚本,用于在任何CI平台中验证提交是否包含符合开发者证书来源(DCO)要求的"Signed-off-by:"行。它确保所有提交都经过贡献者签名认证,适用于需要DCO合规性检查的开源项目。
1. 使用Docker镜像
shell$ docker run --rm -v $(pwd):/repo -w /repo christophebedard/dco-check:latest dco-check
2. 通过PyPI安装
shell$ pip install dco-check $ dco-check
3. 直接下载脚本
shell$ wget https://raw.githubusercontent.com/christophebedard/dco-check/master/dco_check/dco_check.py $ python3 dco_check.py
运行dco-check --help查看完整选项,主要包括:
--ignore-merge-commits:忽略合并提交--default-branch:指定默认分支(默认为"master")--remote:指定远程仓库(默认为"origin")--quiet:静默模式,仅输出错误信息--verbose:详细模式,输出详细检查过程支持通过环境变量设置参数(命令行参数优先级更高),具体变量可通过--help查看。
| CI平台 | 支持默认分支推送检测 | 支持拉取/合并请求检测 | 基础分支获取方式 | 默认分支获取方式 | 说明 |
|---|---|---|---|---|---|
| GitHub | ✓ | ✓ | CI提供 | (未使用) | 使用GitHub API获取提交数据,因GitHub默认使用浅克隆 |
| GitLab | ✓ | ✓ | CI提供 | CI提供 | 支持常规GitLab合并请求和外部(GitHub)合并请求 |
| Azure Pipelines | ✓ | CI提供 | 命令行参数 | ||
| AppVeyor | ✓ | CI提供 | 命令行参数 | ||
| CircleCI | ✓ | CI提供*(或命令行参数) | 命令行参数 | *若提供基础修订版信息则可使用(见示例) | |
| Travis CI | 命令行参数 | 命令行参数 | 作为普通Git仓库默认支持 | ||
| 默认(Git) | 命令行参数 | 命令行参数 | 本地使用;在不支持的CI中若使用浅克隆可能导致问题 |
yaml# .github/workflows/dco.yml name: DCO on: pull_request: push: branches: - master jobs: check: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - name: Set up Python 3.x uses: actions/setup-python@v1 with: python-version: '3.x' - name: Check DCO env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | pip3 install -U dco-check dco-check
yaml# .gitlab-ci.yml variables: DOCKER_DRIVER: overlay2 dco: image: christophebedard/dco-check:latest rules: - if: $CI_MERGE_REQUEST_ID - if: $CI_EXTERNAL_PULL_REQUEST_IID - if: $CI_COMMIT_BRANCH == 'master' script: - pip3 install -U dco-check # 可选 - dco-check
需要Python 3.6及以上版本(因使用f-strings语法)。如有需要支持旧版本Python 3,可通过修改代码移除f-strings实现。
参见CONTRIBUTING.md。
您可以使用以下命令拉取该镜像。请将 <标签> 替换为具体的标签版本。如需查看所有可用标签版本,请访问 标签列表页面。
来自真实用户的反馈,见证轩辕镜像的优质服务