github / github/branch-deploy

Environment-specific `outdated_mode`?

Đang mở
#378 2 bình luận 1 reaction 0 người được giao Xem trên GitHub
enhancement
Ngôn ngữ chính
TypeScript
Star
576
Fork
74
Merge trung bình
11 giờ 7 phút
Pull request đã merge (30 ngày)
1

Mô tả

### Details

On my team, we would like to enforce that our dev environment is always up to date with main, but other environments such as staging and production don't have that requirement, as sometimes we need to branch deploy a hotfix branch there which will most definitely be out of date with main, so the outdated enforcement becomes a hindrance.

For a while we had just disabled outdated checks for all environments, but it's caused the occasional confusion when people accidentally deploy outdated changes to dev where that's unexpected 😅 so we're looking to go back to properly enforcing those rules.

Since the environment/command parsing all happens internal to the branch deploy workflow, I can't figure out a way to make the `outdated_mode` environment specific. For the time being I've implemented a bit of a workaround where I have my own step _after_ the branch deploy step that checks the `environment` and `is_outdated` outputs and responds accordingly, but it's a bit hacky, and has the side-effect of showing the "deployment triggered" comment before then displaying my own custom outdated comment, which certainly isn't ideal 😅

I'm wondering if this is something that would be feasible for the workflow to support internally?

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Read the branch deploy workflow's internal environment and command parsing first, then trace how outdated_mode and the environment/is_outdated outputs are handled. Done means outdated enforcement can differ by environment within the workflow, without a follow-up step or duplicate deployment comment.

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

Đánh giá

Công nghệ
github-actions, typescript
Lĩnh vực
ci-cd, devops
Loại issue
Tính năng
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
38/100

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.