Le lab promouvoir-un-deploiement-approuve : deux environnements, une approbation, la promotion par digest, le rollback sans rebuild

Đang mở
#37 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
56/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
github-actions, python

Hướng nghiên cứu

Start with labs/deployer/promouvoir-un-deploiement-approuve/lab.yaml, scenario.md, challenge/, and solution/, then inspect the referenced lesson paths and run python3 scripts/valider-labs.py --lab . Done means validation reaches 100 after a replayable run, validation-labs.json records the verdict, solution actions pass pinact, zizmor, and actionlint, and meta.yml with tests/test_meta_declare_les_labs.py is green.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Mesuré le 2026-09-25 sur le parcours github-actions.yaml et les leçons du blog.

Lab labs/deployer/promouvoir-un-deploiement-approuve, module deployer. Leçons éprouvées :

  • /docs/pipeline-cicd/github/deployer/lab-promotion/
  • /docs/pipeline-cicd/github/deployer/environments/
  • /docs/pipeline-cicd/github/deployer/protection-rules/
  • /docs/pipeline-cicd/github/deployer/rollback/

La page renvoie vers secure-python-pipeline/blob/main/.github/workflows/deploy.yml (l.241) : le fichier n'existe pas, le dépôt en a sept, aucun ne s'appelle ainsi. Le fork ne produit pas d'image seul (IMAGE en dur, Actions désactivées, pas de release copiée), et gh api user/packages exige le scope read:packages, absent par défaut.

Jouable avec act : non

Environnements protégés, approbation, rétention des secrets, historique des déploiements : plateforme. docker buildx imagetools inspect et gh attestation verify se jouent aussi hors CI.

Ce qui n'est pas qu'un copier-coller

Le déploiement n'est pas ce qu'on vérifie, c'est ce qu'on refuse. Le test plateforme lit gh api repos/$LAB_REPO/deployments?environment=production et exige un déploiement success précédé d'un état waiting (l'approbation), un run depuis une branche autre que main en échec (politique de branches), et deux empreintes de DEPLOY_TOKEN différentes dans les logs de staging et de production. Le rollback est un second déploiement du digest précédent, sans run de release.

Définition de terminé

  • lab.yaml renseigné : module, doc_url, lessons, act (oui, partiel, non) et act_notes qui dit pourquoi
  • scenario.md décrit une situation et un objectif, pas un mode d'emploi ; aucun emoji, aucun tiret cadratin
  • challenge/ est un point de départ que l'apprenant modifie, solution/ une solution de référence rejouable
  • chaque test lit l'état (résultat d'act, findings d'un scanner, réponse de gh api), et le dernier exerce les deux côtés
  • la question « serait-il vert si l'apprenant ne faisait rien ? » a reçu non pour chaque test
  • python3 scripts/valider-labs.py --lab <id> rend 0 avant, 100 après, rejouable ; le verdict est dans validation-labs.json
  • les actions de la solution sont épinglées par SHA au tag mesuré ce jour, commentaire de version vérifié par pinact run --check
  • zizmor --offline et actionlint rendent 0 sur solution/
  • le lab est dans meta.yml, tests/test_meta_declare_les_labs.py est vert
  • quatre indices base64 de coût croissant dans challenge/hints.yaml
Ngôn ngữ chính
Python
Star
7
Fork
4
Merge trung bình
2 ngày 10 giờ
Pull request đã merge (30 ngày)
8

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của stephrobert/github-actions-training

Tất cả issue của stephrobert/github-actions-training

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.