GitHub repository Severityhigh builtIn

Description

An 'Unknown' state codespace indicates that GitHub cannot determine the runtime status - typically due to backend connectivity issues or a half-deleted resource. Codespaces in this state should be reviewed and deleted if they cannot be transitioned back to a known state.

Recommandation

1. Go to https://github.com/codespaces. 
2. For each codespace in 'Unknown' state, attempt to start it. 
3. If start fails or stays Unknown, delete the codespace.

Règle de politique

{
  "target": "GHCodespace",
  "if": {
    "allOf": [
      {
        "resource": "GHCodespace",
        "property": "State",
        "operator": "notEquals",
        "value": "Unknown"
      }
    ]
  },
  "then": {
    "effect": "Audit"
  }
}
Détails de la règle
  • ID de la règle: DOS5805
  • Code: GH_Repository_Codespace_Should_Not_Be_Unknown
  • Plateforme: GitHub
  • Catégorie: repository
  • Sévérité: Severityhigh
  • Type: builtIn