feat: GitHub-style deployment environments and status tracking #227

Open
opened 2026-05-26 21:59:09 +00:00 by jmiller · 0 comments
Owner

Summary

Add deployment environments (similar to GitHub Deployments) that allow repos to define environments (e.g. staging, production) with protection rules, track deployment status per environment, and surface deployment history in the UI.

Motivation

Currently there is no way to:

  • See which commit is deployed to which environment
  • Require approvals before deploying to production
  • Track deployment history (who deployed what, when, rollbacks)
  • Gate deployments behind required status checks

This forces teams to rely on external tools (ArgoCD dashboards, CI logs) to answer basic questions like "what version is in production?"

Proposed Features

Environments

  • Define named environments per repo (e.g. dev, staging, production)
  • Set protection rules: required reviewers, wait timers, branch restrictions
  • Environment secrets (already partially supported by Actions)

Deployment Status API

  • POST /repos/{owner}/{repo}/deployments -- create a deployment
  • POST /repos/{owner}/{repo}/deployments/{id}/statuses -- update status (pending, in_progress, success, failure, inactive)
  • GET /repos/{owner}/{repo}/deployments -- list deployments with filtering

UI

  • Environments tab on repo page showing current deployment per env
  • Deployment history with commit SHA, status, duration, actor
  • Badge on commits showing which environments they are deployed to

Actions Integration

  • environment: key in workflow jobs (already parsed but not enforced)
  • Protection rules gate job execution
  • Automatic deployment status updates from workflow runs

References


Opened by Claude Code on behalf of @jmiller

## Summary Add deployment environments (similar to GitHub Deployments) that allow repos to define environments (e.g. staging, production) with protection rules, track deployment status per environment, and surface deployment history in the UI. ## Motivation Currently there is no way to: - See which commit is deployed to which environment - Require approvals before deploying to production - Track deployment history (who deployed what, when, rollbacks) - Gate deployments behind required status checks This forces teams to rely on external tools (ArgoCD dashboards, CI logs) to answer basic questions like "what version is in production?" ## Proposed Features ### Environments - Define named environments per repo (e.g. dev, staging, production) - Set protection rules: required reviewers, wait timers, branch restrictions - Environment secrets (already partially supported by Actions) ### Deployment Status API - `POST /repos/{owner}/{repo}/deployments` -- create a deployment - `POST /repos/{owner}/{repo}/deployments/{id}/statuses` -- update status (pending, in_progress, success, failure, inactive) - `GET /repos/{owner}/{repo}/deployments` -- list deployments with filtering ### UI - Environments tab on repo page showing current deployment per env - Deployment history with commit SHA, status, duration, actor - Badge on commits showing which environments they are deployed to ### Actions Integration - `environment:` key in workflow jobs (already parsed but not enforced) - Protection rules gate job execution - Automatic deployment status updates from workflow runs ## References - GitHub Deployments API: https://docs.github.com/en/rest/deployments - GitHub Environments: https://docs.github.com/en/actions/deployment/targeting-different-environments - Upstream Gitea issue: https://github.com/go-gitea/gitea/issues/13539 --- *Opened by Claude Code on behalf of @jmiller*
jmiller added the ci-cd label 2026-05-26 21:59:09 +00:00
Sign in to join this conversation.
No labels ci-cd
Status
Type Feature
Status
Priority
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: MokoConsulting/MokoGitea#227