CI/CD: post-deploy image variants job (template #152)
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 82/100
- Loại issue
- Tài liệu
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- github-actions, gitlab, kubernetes, yaml
- Lĩnh vực
- ci-cd, devops, documentation
Hướng nghiên cứu
Đọc content/6.deployment/3.ci-cd.md và phần phát hành tiếp theo trong 7.upgrading-the-template.md, sau đó so sánh các hướng dẫn làm nóng cache hiện có với quy trình biến thể hình ảnh sau triển khai được mô tả ở đây. Ghi lại lệnh, job hoặc bước đặc thù của nền tảng, các tùy chọn, cách xử lý khi thất bại và lý do quy trình chạy trong pod API. Hoàn tất khi cả hai trang giải thích quy trình mới và giữ lại các bước dự phòng thủ công.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Template #152 (on main, next template release) adds a post-deploy job that generates missing imagine variants. content/6.deployment/3.ci-cd.md should describe it next to the cache warm (and 7.upgrading-the-template.md in the next release's section).
What it does:
- Command:
generate_image_variants [track]inbin/devops/k8s.shrunsbin/console silverback:api-components:imagine:generate -vin the API pod (bundle 2.0.0-alpha.15, docs#213). It generates every variant not stored yet, one image at a time, instead of visitors' requests doing it after a new or changed filter. - Purge: if anything was generated, it runs
purge-http-cacheso cached API responses list the new variants. Withprovider cloudflare, that's a purge everything at the edge. - Log: it lists every variant except those already stored.
- Exit codes: 1 means a variant failed; it purges first, then fails the job. 2 means an unknown
--filter/--class.
Where it runs:
- GitLab:
image variants <track>jobs (allow_failure,environment: action: verify) after each deploy job. Eachwarm cache <track>nowneeds:it (optional), so the warm requests pages whose variants exist. - GitHub: a
continue-on-error"Generate image variants" step after fixtures and before the warm, inci.ymlandproduction.yml. - Never fails a deploy: it's a separate job/step.
Switches (per track, like the warm; not GitLab environment-scoped, since staging runs under environment: production):
CWA_CI_IMAGE_VARIANTS_PRODUCTION: on unless"false"CWA_CI_IMAGE_VARIANTS_STAGING,_REVIEW,_CANARY: off unless"true"
Why not a Helm hook Job: purge-http-cache reaches Souin through the API pod's loopback admin API, so a Job pod would purge its own idle Caddy.
Upgrade (next release): copying the job makes the first deploy generate every image's WebP variants (#149) and purge by itself. The manual imagine:generate --dry-run / imagine:generate / purge-http-cache steps remain as the fallback without it.
- Ngôn ngữ chính
- Vue
- Star
- 0
- Fork
- 0
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của components-web-app/docs
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
components-web-app/docs#245 ·
-
Độ khó 2/5 Nửa ngày Mức phù hợp với người mới 68/100
components-web-app/docs#244 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
components-web-app/docs#243 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
components-web-app/docs#241 ·
-
documentation
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 15/100
components-web-app/docs#246 ·
Tất cả issue của components-web-app/docs
Issue tương tự
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
devantler-tech/ksail#7836 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
SasanLabs/VulnerableApp#836 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
needs-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
gke-labs/kube-agents#3394 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area/CI area/CI/automation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
Apicurio/apicurio-registry#10620 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
fluent/helm-charts#764 ·