Skip to content

Add kubectl oadp backup resource-status and vm-status commands #271

Description

@Joeavaikath

Summary

Add CLI commands that expose per-item backup outcomes using the rollup library from #270.

Parent: #269 (OADP-8697)
Depends on: #270
Design: oadp-operator/docs/design/backup_resource_rollup-design.md (local; pending upstream PR — see parent #269)

Commands

kubectl oadp backup resource-status <backup>

Generic rollup command.

Flags (proposed):

  • --group-by=owner:VirtualMachine — group by owning resource kind (also supports owner, label:<key>)
  • --namespace — backup namespace (if not inferable)
  • -o json|yaml|table — output format (default: failures-first table)
  • --group-by-reason — aggregate failures by reason code
  • --show-all — include succeeded/skipped rows (default: failures only)

kubectl oadp backup vm-status <backup>

Convenience alias for OADP-8697: resource-status with --group-by=owner:VirtualMachine and VM-oriented column headers.

Default UX

Failures-first table for operability at scale:

$ kubectl oadp backup vm-status oadp-8697-multi-vm-backup
Backup: oadp-8697-multi-vm-backup   Phase: PartiallyFailed
VMs: 5 total   3 succeeded   2 failed   0 skipped

FAILED:
NAME                      NAMESPACE            REASON              DETAIL
vm-broken-baddatasource   oadp-8697-multi-vm   MissingDataSource   ...
vm-broken-orphan-pvc      oadp-8697-multi-vm   MissingPVC          ...

JSON output should be stable for scripting/automation.

Acceptance criteria

Non-goals

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementnew feature or improvements to existing onesgoPull requests that update go code

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions