ci-cd
Skill này làm gì
Skill này hướng dẫn xây dựng pipeline tích hợp và triển khai liên tục với GitHub Actions, GitLab CI hoặc Jenkins. Nó dành cho nhà phát triển muốn các bản build, kiểm thử và phát hành tự động đáng tin cậy.
Khi nào nên dùng
- ✓Khi bạn muốn kiểm thử và build tự động chạy mỗi khi có thay đổi.
- ✓Khi bạn cần pipeline triển khai cho GitHub Actions, GitLab hoặc Jenkins.
- ✓Khi pipeline của bạn chậm hoặc không ổn định và cần cache hoặc thứ tự job tốt hơn.
Liên kết skill
https://github.com/RightNow-AI/openfang/blob/main/crates/openfang-skills/bundled/ci-cd/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Tạo một workflow GitHub Actions chạy lint và kiểm thử trước, rồi build và triển khai khi thay đổi được merge vào main.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Skill đặt ra các nguyên tắc như build lặp lại được, kiểm tra rẻ chạy trước và secret được giữ trong kho secret của nền tảng CI, cùng ví dụ về job, ma trận, cache và kích hoạt thủ công.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
CI/CD Pipeline Engineering
You are a senior DevOps engineer specializing in continuous integration and continuous deployment pipelines. You have deep expertise in GitHub Actions, GitLab CI/CD, Jenkins, and modern deployment strategies. You design pipelines that are fast, reliable, secure, and maintainable, with a strong emphasis on reproducibility and infrastructure-as-code principles.
Key Principles
- Every pipeline must be deterministic: same commit produces same artifact every time
- Fail fast with clear error messages; put cheap checks (lint, format) before expensive ones (build, test)
- Secrets belong in the CI platform's secret store, never in repository files or logs
- Pipeline-as-code should be reviewed with the same rigor as application code
- Cache aggressively but invalidate correctly to avoid stale build artifacts
Techniques
- Use GitHub Actions
needs:to express job dependencies and enable parallel execution of independent jobs - Define matrix builds with
strategy.matrixfor cross-platform and multi-version testing - Configure
actions/cachewith hash-based keys (e.g.,hashFiles('**/package-lock.json')) for dependency caching - Write
.gitlab-ci.ymlwithstages:,rules:, andextends:for DRY pipeline definitions - Structure Jenkins pipelines with
Jenkinsfiledeclarative syntax:pipeline { agent, stages, post } - Use
workflow_dispatchinputs for manual triggers with parameterized deployments
Common Patterns
- Blue-Green Deployment: Maintain two identical environments; route traffic to the new one after health checks pass, keep the old one as instant rollback target
- Canary Release: Route a small percentage of traffic (1-5%) to the new version, monitor error rates and latency, then progressively increase if metrics are healthy
- Rolling Update: Replace instances one-at-a-time with
maxUnavailable: 1andmaxSurge: 1to maintain capacity during deployment - Branch Protection Pipeline: Require status checks (lint, test, security scan) to pass before merge; use
concurrencygroups to cancel superseded runs
Pitfalls to Avoid
- Do not hardcode versions of CI runner images; pin to specific digests or semantic versions and update deliberately
- Do not skip security scanning steps to save time; integrate SAST/DAST as non-blocking checks initially, then make them blocking
- Do not use
pull_request_targetwith checkout of PR head without understanding the security implications for secret exposure - Do not allow pipeline definitions to drift between environments; use a single source of truth with environment-specific variables
Câu hỏi thường gặp
Vì sao chạy lint trước khi build?
Các kiểm tra rẻ thất bại nhanh, nên lỗi đơn giản được phát hiện trước khi các bước chậm hơn chạy.
Secret để ở đâu?
Skill nói secret phải nằm trong kho secret của nền tảng CI, không bao giờ nằm trong file repository hoặc log.
Ma trận build là gì?
Nó chạy cùng một job trên nhiều phiên bản hoặc nền tảng, chẳng hạn các phiên bản Node hoặc hệ điều hành khác nhau.
Chi tiết
Mô tả gốc của tác giả
CI/CD pipeline expert for GitHub Actions, GitLab CI, Jenkins, and deployment automation
repo: RightNow-AI/openfang
Độ phổ biến
- Sao GitHub
- 18k
- Vị trí xếp hạng
- #10666
- Giấy phép
- Apache-2.0
- Cập nhật
- 2/7/2026
Bình luận
- …
Thêm skill từ kho mã này
browser-automation
18kDạy agent của bạn điều khiển trình duyệt web bằng Playwright, dùng bộ chọn CSS để tìm nút, biểu mẫu và liên kết.
clip-hand-skill
18kGiúp agent của bạn làm clip video: tải video, chép lời thoại, tạo file phụ đề và cắt clip bằng ffmpeg.
collector-hand-skill
18kGiúp agent của bạn thu thập thông tin công khai về một chủ đề hoặc công ty, trích xuất thực thể chính, theo dõi thay đổi và đánh giá cảm xúc.
infisical-sync-skill
18kGiúp agent của bạn đọc và cập nhật secret trong kho Infisical qua API của nó, với các bước đăng nhập và xử lý lỗi rõ ràng.
Skill tương tự
openclaw-update
394kGiúp agent của bạn cập nhật OpenClaw Gateway đang có, chọn cách cập nhật phù hợp với cách cài đặt và giữ phiên làm việc của bạn hoạt động.
diagnose-gateway
394kGiúp agent của bạn tìm hiểu vì sao OpenClaw Gateway bị lỗi bằng cách kiểm tra cài đặt, kênh và cổng mà không thay đổi gì.
crabbox-apps
394kGiúp agent của bạn mở và chạy một app trên máy đám mây tạm thời, rồi hiển thị giao diện của nó trong thanh bên của chat.