Token导航 LogoToken导航TokenDH.com
研究检索执行命令github未标认证来源可访问许可证需确认审计通过

gitlab-ci-validatorGitLab CI validator 搜索

Agent Skill

用于围绕 GitLab 项目、Merge Request、Issue、分支、流水线和代码审查流程提供辅助能力。它适合让 Agent 查询项目状态、整理提交差异、辅助检查合并请求或汇总 CI 结果。使用时需要确认项目权限、访问 token 和目标分支范围;涉及合并、推送、改工单或触发流水线时,应先预览影响并核对团队流程。

总安装

3,143

周安装

135

GitHub Stars

197

下载量

1,102
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:gitlab-ci-validator(GitLab CI validator 搜索)
来源仓库:https://github.com/akin-ozer/cc-devops-skills
仓库路径:skills/gitlab-ci-validator
安装命令:
npx skills add https://github.com/akin-ozer/cc-devops-skills --skill gitlab-ci-validator
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/akin-ozer/cc-devops-skills --skill gitlab-ci-validator

简介

用于围绕 GitLab 项目、Merge Request、Issue 等流程提供辅助能力。

  • 适合查询项目状态、整理提交差异、辅助检查合并请求或汇总 CI 结果。
  • 使用时需确认项目权限和访问 token,涉及合并或改工单应预览影响。
  • 安装方式:通过 npx 从指定 GitHub 仓库添加技能。
  • 建议在使用前核对团队流程和目标分支范围。

SKILL.md

GitLab CI/CD Validator

Comprehensive toolkit for validating, linting, testing, and securing .gitlab-ci.yml configurations.

Trigger Phrases

Use this skill when requests include intent like:

  • "Validate this .gitlab-ci.yml"
  • "Why is this GitLab pipeline failing?"
  • "Run a security review for our GitLab CI"
  • "Check pipeline best practices"
  • "Lint GitLab CI config before merge"

Setup And Prerequisites (Run First)

All commands below assume repository root as current working directory.

# Ensure validator scripts are executable
chmod +x devops-skills-plugin/skills/gitlab-ci-validator/scripts/*.sh \
  devops-skills-plugin/skills/gitlab-ci-validator/scripts/*.py

# Required runtime
python3 --version

Use one canonical command path for orchestration:

VALIDATOR="bash devops-skills-plugin/skills/gitlab-ci-validator/scripts/validate_gitlab_ci.sh"

Optional local execution tooling (for --test-only):

bash devops-skills-plugin/skills/gitlab-ci-validator/scripts/install_tools.sh

Quick Start Commands

# 1) Full validation (syntax + best practices + security)
$VALIDATOR .gitlab-ci.yml

# 2) Syntax and schema only (required first gate)
$VALIDATOR .gitlab-ci.yml --syntax-only

# 3) Best-practices only (recommended)
$VALIDATOR .gitlab-ci.yml --best-practices

# 4) Security only (required before merge)
$VALIDATOR .gitlab-ci.yml --security-only

# 5) Optional local pipeline structure test (needs gitlab-ci-local + Docker)
$VALIDATOR .gitlab-ci.yml --test-only

# 6) Strict mode (treat best-practice warnings as failure)
$VALIDATOR .gitlab-ci.yml --strict

Deterministic Validation Workflow

Follow these gates in order:

  1. Run Quick Start command 2 (--syntax-only).
  2. If syntax fails, stop and fix errors before continuing.
  3. Run Quick Start command 3 (--best-practices) and apply relevant improvements.
  4. Run Quick Start command 4 (--security-only) and fix all critical/high findings before merge.
  5. Optionally run Quick Start command 5 (--test-only) for local execution checks.
  6. Run Quick Start command 6 (--strict) for final merge gate.

Required gates: syntax + security. Recommended gate: best practices. Optional gate: local execution test.

Rule Severity Rationale And Documentation Links

Severity Model

  • critical: Direct credential/secret exposure or high-confidence compromise path. Block merge.
  • high: Exploitable unsafe behavior or strong security regression. Fix before merge.
  • medium: Security hardening gap with realistic risk. Track and fix soon.
  • low/suggestion: Optimization or maintainability improvement.

Rule Classes And Why They Matter

  • Syntax rules (yaml-syntax, job-stage-undefined, dependencies-undefined-job): prevent pipeline parse and dependency failures.
  • Best-practice rules (cache-missing, artifact-no-expiration, dag-optimization): reduce runtime cost and improve pipeline throughput.
  • Security rules (hardcoded-password, curl-pipe-bash, include-remote-unverified): reduce credential leaks and supply-chain risk.

References

Fallbacks For Tool Or Environment Constraints

  • Missing python3:

- Behavior: validator cannot run. - Fallback: install Python 3 and rerun.

  • Missing PyYAML:

- Behavior: python_wrapper.sh auto-creates .venv and installs pyyaml when possible. - Fallback in restricted/offline environments: pre-install pyyaml from an internal mirror, then rerun.

  • Missing gitlab-ci-local, node, or docker:

- Behavior: --test-only reports warning/failure. - Fallback: skip local execution testing and continue with syntax/best-practice/security gates.

  • No execute permission on scripts:

- Behavior: shell permission errors. - Fallback: rerun the setup chmod command from the Setup section.

Examples

Example 1: New Pipeline Validation

$VALIDATOR examples/basic-pipeline.gitlab-ci.yml --syntax-only
$VALIDATOR examples/basic-pipeline.gitlab-ci.yml --security-only

Example 2: Pre-Merge Hard Gate

$VALIDATOR .gitlab-ci.yml --strict

Example 3: CI Integration

stages:
  - validate

validate_gitlab_ci:
  stage: validate
  script:
    - chmod +x devops-skills-plugin/skills/gitlab-ci-validator/scripts/*.sh devops-skills-plugin/skills/gitlab-ci-validator/scripts/*.py
    - bash devops-skills-plugin/skills/gitlab-ci-validator/scripts/validate_gitlab_ci.sh .gitlab-ci.yml --strict

Individual Validators (Advanced)

# Syntax validator (via wrapper for PyYAML fallback)
bash devops-skills-plugin/skills/gitlab-ci-validator/scripts/python_wrapper.sh \
  devops-skills-plugin/skills/gitlab-ci-validator/scripts/validate_syntax.py .gitlab-ci.yml

# Best-practices validator
bash devops-skills-plugin/skills/gitlab-ci-validator/scripts/python_wrapper.sh \
  devops-skills-plugin/skills/gitlab-ci-validator/scripts/check_best_practices.py .gitlab-ci.yml

# Security validator
bash devops-skills-plugin/skills/gitlab-ci-validator/scripts/python_wrapper.sh \
  devops-skills-plugin/skills/gitlab-ci-validator/scripts/check_security.py .gitlab-ci.yml

Done Criteria

  • Frontmatter name and description unchanged.
  • One canonical orchestrator path is used consistently.
  • Setup and chmod prerequisites appear before workflow/use examples.
  • Quick-start and workflow are non-duplicative (workflow references quick-start gates).
  • Severity rationale and rule-to-doc references are explicit.
  • Fallback behavior is documented for missing tools and constrained environments.
  • Examples are executable from repository root.

Notes

  • This skill validates configuration and static patterns; it does not execute production pipelines.
  • Use gitlab-ci-local or GitLab CI Lint for runtime behavior confirmation.

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

39.17%
按下载量换算432

Claude

30.29%
按下载量换算334

Cursor

17.72%
按下载量换算195

Gemini CLI

8.65%
按下载量换算95

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/akin-ozer/cc-devops-skills --skill gitlab-ci-validator 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills