openebs/mayastor-fio-spdk该Docker镜像为Mayastor存储系统提供CI/CD测试工具,旨在通过自动化测试流程,确保Mayastor在持续集成(CI)和持续部署(CD)环境中的功能正确性、性能稳定性及兼容性。主要用于开发团队在代码提交、版本构建及部署前的自动化验证,减少人工测试成本,加速开发迭代。
bashdocker pull mayastor/test-utility:latest
bashdocker run --rm \ -e MAYASTOR_VERSION=v2.5.0 \ # 指定目标Mayastor版本 -e TEST_TYPE=functional \ # 测试类型:functional/integration/performance -v $(pwd)/reports:/reports \ # 挂载宿主机目录存储测试报告 mayastor/test-utility:latest
yamlversion: '3.8' services: mayastor-test: image: mayastor/test-utility:latest environment: - MAYASTOR_VERSION=v2.5.0 - TEST_TYPE=integration - REPORT_FORMAT=junit # 报告格式:junit/html - LOG_LEVEL=info # 日志级别:debug/info/warn/error volumes: - ./test-reports:/reports - ./test-config:/config # 挂载自定义测试配置文件 network_mode: host # 如需访问宿主机Mayastor服务,可使用host网络
| 环境变量名 | 描述 | 默认值 | 可选值 |
|---|---|---|---|
MAYASTOR_VERSION | 目标测试的Mayastor版本 | latest | 如v2.4.1、v2.5.0-rc1等 |
TEST_TYPE | 测试类型 | functional | functional/integration/performance |
REPORT_FORMAT | 测试报告格式 | junit | junit/html |
REPORT_PATH | 容器内报告存储路径 | /reports | 自定义路径(需配合卷挂载) |
LOG_LEVEL | 日志输出级别 | info | debug/info/warn/error |
TEST_TIMEOUT | 单测试用例超时时间(秒) | 300 | 正整数 |
CUSTOM_CONFIG_PATH | 自定义测试配置文件路径 | /config | 需通过卷挂载外部配置文件 |
在.gitlab-ci.yml中添加测试阶段:
yamlstages: - test mayastor-test: stage: test image: mayastor/test-utility:latest variables: MAYASTOR_VERSION: v2.5.0 TEST_TYPE: integration REPORT_FORMAT: junit script: - /entrypoint.sh # 镜像内置入口脚本,执行测试流程 artifacts: paths: - reports/ # 保存测试报告为CI制品 reports: junit: reports/junit.xml # GitLab自动解析JUnit报告





manifest unknown 错误
TLS 证书验证失败
DNS 解析超时
410 错误:版本过低
402 错误:流量耗尽
身份认证失败错误
429 限流错误
凭证保存错误
来自真实用户的反馈,见证轩辕镜像的优质服务