Commit Graph
6784 Commits
Author SHA1 Message Date
Shubham PampattiwarandGitHub a96f567f38 Add Community section with meeting info to README (#10468)
The README had no reference to Velero's community meetings, which CLOMonitor
flags via the community_meeting check. Community meeting details already live
on the community page but were not discoverable from the README.

Add a Community section linking the bi-weekly community meetings, project
meeting calendar, YouTube archive, Slack, and mailing list.

Part of the CNCF incubation readiness work (#10383).

Signed-off-by: Shubham Pampattiwar <spampatt@redhat.com>
2026-09-03 13:55:19 -04:00
Shubham PampattiwarandGitHub 1d9391b85e Evaluate changelog exemption labels from live PR state (#10472)
The changelog check decided whether a PR was exempt using the labels in
the triggering event payload (github.event.pull_request.labels). That
payload is frozen at event time, so a PR that gets the
kind/changelog-not-required label after its first run could not pass by
re-running the failed job, and the exemption only took effect if a brand
new event happened to fire afterward.

Move the exemption logic into hack/changelog-check.sh and query the PR's
current labels via the GitHub API instead. Re-runs and labels added after
the initial run are now evaluated correctly. The workflow grants
pull-requests: read and passes github.token so the script can read labels.

The exempt label set (kind/changelog-not-required, Design, Website,
Documentation) is unchanged.

Signed-off-by: Shubham Pampattiwar <spampatt@redhat.com>
2026-09-03 09:58:20 -07:00
Shubham PampattiwarandGitHub fea3e27e9a Add OpenSSF Security Insights manifest and dependency management docs (#10470)
Add a schema-valid OpenSSF Security Insights v2 (2.2.0) manifest at
SECURITY-INSIGHTS.yml describing the project's maintainers, vulnerability
reporting process, license, and links to governance, security, and
dependency management policies.

Also add a Dependency management section to the development docs covering
Go modules, Dependabot automation, review process, and how security
relevant dependency updates are handled. The manifest references this
section as the dependency management policy.

This improves the project's CLOMonitor score by satisfying the
security_insights and dependencies_policy checks.

Signed-off-by: Shubham Pampattiwar <spampatt@redhat.com>
2026-09-03 11:39:42 -04:00
Wenkai Yin(尹文开)andGitHub ccfdce30f9 Fall back to full restore rather than fail if fail to get the volume ID (#10465)
Run the E2E test on kind / setup-test-matrix (push) Failing after 4s
e2e-test-kind.yaml / extract (push) Failing after 7s
Run the E2E test on kind / get-go-version (push) Failing after 8s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 7s
Main CI / get-go-version (push) Failing after 8s
Main CI / Build (push) Skipped
Fall back to full restore rather than fail if fail to get the volum
e ID

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>
2026-09-03 14:56:35 +08:00
lyndon-liandGitHub 6cf70c3e3a Merge pull request #10422 from Lyndon-Li/use-pv-topology-for-block-data-mover-for-windows
e2e-test-kind.yaml / extract (push) Failing after 7s
Run the E2E test on kind / get-go-version (push) Failing after 9s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / setup-test-matrix (push) Failing after 2s
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 8s
Main CI / get-go-version (push) Failing after 10s
Main CI / Build (push) Skipped
Use pv topology for block data mover for windows
2026-09-03 13:22:55 +08:00
Lyndon-Li a0e526768b fix shadow error problem
Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
2026-09-03 11:20:23 +08:00
Lyndon-Li 7ea7a25050 Merge branch 'main' into use-pv-topology-for-block-data-mover-for-windows 2026-09-03 11:19:11 +08:00
Chlins ZhangandGitHub 5bcac16213 Merge pull request #10464 from chlins/fix/error-message-context
Add operation context to user-facing error messages
2026-09-03 10:34:21 +08:00
Adam ZhangandGitHub 85c660612b Enforce resource filters on cluster-wide items (#10455)
Run the E2E test on kind / setup-test-matrix (push) Failing after 4s
e2e-test-kind.yaml / extract (push) Failing after 10s
Run the E2E test on kind / get-go-version (push) Failing after 11s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 6s
Main CI / get-go-version (push) Failing after 7s
Main CI / Build (push) Skipped
* Enforce resource filters on cluster-wide items

When backups query all namespaces (wildcard or omitted includes),
the item collector retrieved resources in bulk, bypassing
per-namespace resource filter policies in Stage 1 collection.
This caused resources not listed in the policy to be backed up.

To preserve cluster-wide query performance while enforcing policy
rules, evaluate namespace exclusions, resource kind allowlists,
and label selectors in memory for each collected item.

Signed-off-by: Adam Zhang <adam.zhang@broadcom.com>

* Optimize in-memory resource filter checks

Optimize per-item filter evaluation in the item collector:
- Precalculate GroupResource string once per resource type
- Skip filter policy evaluation when no namespaced policies exist
- Restrict in-memory filtering to cluster-wide queries
- Cache consecutive namespace lookups across collected items
- Lazily extract resource labels only when selectors are present

Signed-off-by: Adam Zhang <adam.zhang@broadcom.com>

---------

Signed-off-by: Adam Zhang <adam.zhang@broadcom.com>
2026-09-02 12:03:06 -04:00
chlins e03ff894ff Add operation context to user-facing error messages
Prefix raw err.Error() strings surfaced in CR statuses and CLI stderr with the failed operation.

Signed-off-by: chlins <chlins.zhang@gmail.com>
2026-09-02 15:38:36 +08:00
Xun Jiang/Bruce JiangandGitHub 125b5cc963 Merge pull request #10458 from velero-io/copilot/skip-kine-tests-on-no-go-changes
Run the E2E test on kind / setup-test-matrix (push) Failing after 4s
e2e-test-kind.yaml / extract (push) Failing after 7s
Run the E2E test on kind / get-go-version (push) Failing after 8s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 6s
Main CI / get-go-version (push) Failing after 7s
Main CI / Build (push) Skipped
Skip kind E2E tests on PRs that don't touch Go code or the workflow itself
2026-09-02 14:22:49 +08:00
Xun Jiang/Bruce JiangandGitHub 51e3075e78 Merge pull request #10453 from opbot-xd/fix-ginkgo-v2-cleanup-10440
test: resolve remaining Ginkgo V2 and Gomega anti-patterns
2026-09-02 14:19:58 +08:00
Chlins ZhangandGitHub efc69c61aa Add in-place restore pre-flight check: target PVC must not be in use (#10419)
Run the E2E test on kind / setup-test-matrix (push) Failing after 4s
e2e-test-kind.yaml / extract (push) Failing after 7s
Run the E2E test on kind / get-go-version (push) Failing after 7s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 5s
Main CI / get-go-version (push) Failing after 6s
Main CI / Build (push) Skipped
Check the target PVC is not used by any active pod before any side
effect, on both the CSI data mover path and the file system path.
The in-use semantics align with the pvc-protection controller:
terminal-phase pods don't block, terminating pods block with a wait
hint. On the file system path, pods gated by this restore's
restore-wait init container (identified by the restore UID in its args,
and not yet terminated) are exempted: they must mount the PVC for the
node-agent to restore the data and cannot write to the volume until the
PodVolumeRestores complete. Leftover pods, controller-recreated pods,
and pods gated by a different restore still block.

Signed-off-by: chlins <chlins.zhang@gmail.com>
2026-09-01 17:08:25 +08:00
Wenkai Yin(尹文开)andGitHub 25b21f3c5c Get the volume ID before creating the restore PVC, otherwise the existing PV may be deleted during the creation of restore PVC (#10435)
Get the volume ID before creating the restore PVC, otherwise the existing PV may be deleted during the creation of restore PVC

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>
2026-09-01 15:45:22 +08:00
Wenkai Yin(尹文开)andGitHub 07768e7b33 Add "IncrementalBytes" field to status of DataDownload and PVR to indicate data transferred by the incremental restore (#10421)
Add "IncrementalBytes" field to status of DataDownload and PVR to indicate data transferred by the incremental restore

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>
2026-09-01 15:43:53 +08:00
Chlins ZhangandGitHub c3ccc8faf2 Merge pull request #10403 from velero-io/copilot/follow-up-pr-for-daemonset-checks
Check both daemonsets before returning non-NotFound lookup error in IsReady
2026-09-01 14:59:08 +08:00
Chlins ZhangandGitHub 0b0ac253df Merge pull request #10418 from opbot-xd/add-itemblock-unit-tests
Testing: Add missing unit tests for pkg/itemblock
2026-09-01 14:18:57 +08:00
lyndon-liandGitHub 58e788f962 Merge branch 'main' into copilot/follow-up-pr-for-daemonset-checks
Run the E2E test on kind / setup-test-matrix (push) Failing after 4s
e2e-test-kind.yaml / extract (push) Failing after 6s
Run the E2E test on kind / get-go-version (push) Failing after 12s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
2026-09-01 13:36:50 +08:00
opbot_xd 66fd079abb changelog: add changelog for PR 10453
Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>
2026-09-01 06:46:48 +05:30
opbot_xd a607892eb0 test: resolve remaining Ginkgo V2 and Gomega anti-patterns (#10440)
- Replaced Expect().Should() and Expect().ShouldNot() with .To() and .ToNot() across 12 files (Task 1).
- Replaced synchronously evaluated Eventually() with Expect() in server_status_request_controller_test.go (Task 2B).
- Extracted Skip() calls inside lazy callbacks into conditional checks using slices.Contains() in enable_api_group_extentions.go (Task 3).

Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>
2026-09-01 06:43:04 +05:30
Chlins ZhangandGitHub 3d50723567 Merge pull request #10439 from M-Phansa/main
Run the E2E test on kind / setup-test-matrix (push) Failing after 4s
e2e-test-kind.yaml / extract (push) Failing after 6s
Run the E2E test on kind / get-go-version (push) Failing after 8s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 6s
Main CI / get-go-version (push) Failing after 7s
Main CI / Build (push) Skipped
chore(deps): bump klauspost/compress to v1.19.2
2026-08-31 22:13:41 +08:00
Xun Jiang/Bruce JiangandGitHub 83f1cca172 Merge branch 'main' into main 2026-08-31 22:03:07 +08:00
Chlins ZhangandGitHub 33837af0b2 Merge pull request #10447 from velero-io/dependabot/github_actions/github-actions-945960c055
Run the E2E test on kind / setup-test-matrix (push) Failing after 3s
e2e-test-kind.yaml / extract (push) Failing after 10s
Run the E2E test on kind / get-go-version (push) Failing after 12s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 6s
Main CI / get-go-version (push) Failing after 7s
Main CI / Build (push) Skipped
Bump the github-actions group with 2 updates
2026-08-31 14:10:31 +08:00
Chlins ZhangandGitHub f87f57ab98 Merge pull request #10376 from opbot-xd/fix-context-propagation
Fix context propagation bug in GetDefaultBackupStorageLocations and add missing test coverage
2026-08-31 13:41:28 +08:00
Chlins ZhangandGitHub 61f9a3aa9a Merge pull request #10430 from Lyndon-Li/enhance-doc-for-backup-deletion
Run the E2E test on kind / setup-test-matrix (push) Failing after 3s
e2e-test-kind.yaml / extract (push) Failing after 6s
Run the E2E test on kind / get-go-version (push) Failing after 7s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 5s
Main CI / get-go-version (push) Failing after 7s
Main CI / Build (push) Skipped
Enhance the doc for backup deletion
2026-08-31 10:27:29 +08:00
R4mboandGitHub 7707681783 add test coverage for CleanupVolumeSnapshot (#10198)
Signed-off-by: samay43 <samayrbhat43@gmail.com>
2026-08-30 21:40:25 -04:00
dependabot[bot]andGitHub 023d5ad471 Bump the github-actions group with 2 updates
Bumps the github-actions group with 2 updates: [helm/kind-action](https://github.com/helm/kind-action) and [github/codeql-action](https://github.com/github/codeql-action).


Updates `helm/kind-action` from 7a97ed793754775518f9db3a8151ee7461dc9c31 to c72b4750145dbfb1c71734c3782a4db35a1c65c0
- [Release notes](https://github.com/helm/kind-action/releases)
- [Commits](https://github.com/helm/kind-action/compare/7a97ed793754775518f9db3a8151ee7461dc9c31...c72b4750145dbfb1c71734c3782a4db35a1c65c0)

Updates `github/codeql-action` from 4.37.7 to 4.37.9
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v4.37.7...v4.37.9)

---
updated-dependencies:
- dependency-name: helm/kind-action
  dependency-version: c72b4750145dbfb1c71734c3782a4db35a1c65c0
  dependency-type: direct:production
  dependency-group: github-actions
- dependency-name: github/codeql-action
  dependency-version: 4.37.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: github-actions
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-29 19:15:03 +00:00
Adam ZhangandGitHub edcaeff91d Merge pull request #10167 from samay43/fix/backup-name-validation
Run the E2E test on kind / setup-test-matrix (push) Failing after 7s
e2e-test-kind.yaml / extract (push) Failing after 11s
Run the E2E test on kind / get-go-version (push) Failing after 12s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 8s
Main CI / get-go-version (push) Failing after 9s
Main CI / Build (push) Skipped
validate backup name format before contacting the API server
2026-08-29 22:22:36 +08:00
Adeet Phanse cf2ad280d7 chore(deps): bump klauspost/compress to v1.19.2
Signed-off-by: Adeet Phanse <adeet.phanse@mongodb.com>
2026-08-28 16:03:55 -04:00
Lyndon-Li f4d9bef51a enhance the doc for backup deletion
Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
2026-08-28 12:50:50 +08:00
Tiger KaovilaiandGitHub 8bb0d9d0c7 Merge branch 'main' into copilot/follow-up-pr-for-daemonset-checks
Run the E2E test on kind / setup-test-matrix (push) Failing after 3s
e2e-test-kind.yaml / extract (push) Failing after 8s
Run the E2E test on kind / get-go-version (push) Failing after 8s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
2026-08-27 12:47:23 -04:00
Lyndon-Li 83e5f9b85a UT for pv topology
Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
2026-08-27 18:22:47 +08:00
lyndon-liandGitHub 72466dbd52 Merge branch 'main' into use-pv-topology-for-block-data-mover-for-windows 2026-08-27 17:06:15 +08:00
Lyndon-Li f6aab3b144 UT for pv topology
Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
2026-08-27 17:03:20 +08:00
Lyndon-Li 564471b9a2 use PV topology over selected node for block data mover for windows
Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
2026-08-27 15:04:55 +08:00
Krishna AwasthiandGitHub 836689f6cc test: Unify duplicate test harness structs in restore and delete tests (#10362)
Run the E2E test on kind / setup-test-matrix (push) Failing after 3s
e2e-test-kind.yaml / extract (push) Failing after 12s
Run the E2E test on kind / get-go-version (push) Failing after 13s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 8s
Main CI / get-go-version (push) Failing after 9s
Main CI / Build (push) Skipped
* test: Unify duplicate test harness structs in restore and delete tests

Extract the duplicated test harness (fakeRestorer, Harness struct, and
AddResource/AddItems helpers) from restore_test.go and
delete_item_action_handler_test.go into a shared pkg/test.Harness.

Backup tests are intentionally excluded: the shared AddResource strips
metadata.creationTimestamp and status (restore semantics), which would
change what the backup tests tar up and assert on.

Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>

* ci: retry

Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>

* ci: retry

Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>

---------

Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>
2026-08-27 13:54:48 +08:00
PranjalandGitHub ea3abc3107 Reject velero backup delete when BSL is read-only (#10353)
The CLI now checks backup storage location access mode before submitting
a delete request. Also reject backups with no storage location set and
cache BSL lookups when deleting multiple backups.

Fixes #4203

Signed-off-by: PranjalManhgaye <manhgayepranjal@gmail.com>
2026-08-27 13:45:51 +08:00
opbot_xd 53eb2b7b70 ci: retry e2e tests
Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>
2026-08-27 05:59:18 +05:30
opbot_xd e67e08ce2f Testing: Add missing unit tests for pkg/itemblock
Add comprehensive unit tests for pkg/itemblock which previously had
zero test coverage. The new tests cover AddUnstructured and FindItem
methods with 14 test cases across 3 test functions, including preferred
GVR ordering, nil item handling, namespace/name filtering, unparseable
apiVersion handling, and cluster-scoped resource matching.

Fixes #10418

Signed-off-by: opbot_xd <awasthikrishna23052005@gmail.com>
2026-08-27 05:43:05 +05:30
de35c2f8be Restrict e2e-test-kind PR trigger to Go/workflow changes
Co-authored-by: kaovilai <11228024+kaovilai@users.noreply.github.com>
2026-08-26 15:51:25 +00:00
Tiger KaovilaiandGitHub e7286d6ff2 Merge branch 'main' into copilot/follow-up-pr-for-daemonset-checks 2026-08-26 10:28:24 -04:00
b7d83a6f2b Cherry pick the in-place restore implementation PRs from feature branch to main (#10415)
* Update CRDs and CLI to support in-place restore (#10038)

Update CRDs(Restore, DataDownload, PodVolumeRestore) and restore create CLI to support in-place restore

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>

* Update Kopia(filesystem) uploader to support incremental and deleteExtraFile during restore (#10066)

Update Kopia(filesystem) uploader to support incremental and deleteExtraFile during restore

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>

* Update Restore Exposer and PVC CSI to support in-place restore (#10104)

1. Update Restore Exposer to support exposing with existing PV for in-place restore
2. Update PVC CSI RIA to continue the restore process for in-place restore

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>

* Update Block uploader to support increase restore (#10244)

Update Block uploader to support increase restore

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>

* Update Exposer to recreate the target PV if the volume mode is different with the restore PVC (#10257)

Update Exposer to recreate the target PV if the volume mode is different with t
he restore PVC

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>

* Preserve PVC selected-node annotation via carrier annotation for in-place restore

For in-place volume data restore, the existing PVC is deleted and
recreated. For StorageClasses with the WaitForFirstConsumer volume
binding mode, losing the volume.kubernetes.io/selected-node annotation
could let the scheduler place the recreated workload Pod in a different
zone than the original PV, leaving it stuck in ContainerCreating.

Instead of relying on RestoreItemAction execution order (the generic
PVC RIA unconditionally strips the selected-node annotation), the PVC
CSI RIA now captures the annotation from the existing PVC right before
deleting it and carries it on the target PVC via the Velero-internal
restore.velero.io/inplace-restore-selected-node annotation. The restore
engine translates the carrier back to the Kubernetes annotation after
all RestoreItemActions have run and always strips the carrier so it
never lands on the cluster.

This makes the behavior independent of RIA ordering: the Kubernetes
annotation is stripped by default on every path (including when the
target PVC does not exist and Velero falls back to provisioning a new
PVC), and preservation only happens when the CSI RIA explicitly
captured a value from the existing PVC.

Signed-off-by: chlins <chlins.zhang@gmail.com>

* Update the control path to make the in-place incremental restore with block data mover work E2E (#10410)

Update the control path to make the in-place incremental restore with block data mover work E2E

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>

---------

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>
Signed-off-by: chlins <chlins.zhang@gmail.com>
Co-authored-by: chlins <chlins.zhang@gmail.com>
2026-08-26 10:21:32 -04:00
Tiger KaovilaiandGitHub ac5744c7b4 docs: move community meeting links to LFX Zoom, add calendar (#10409)
Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
2026-08-26 07:24:30 -04:00
R4mboandGitHub a3d585f78d stop routing credential selection on AZURE_USERNAME after username/password removal (#10363)
* stop routing credential selection on AZURE_USERNAME after username/password removal

Signed-off-by: samay43 <samayrbhat43@gmail.com>

* add changelog entry

Signed-off-by: samay43 <samayrbhat43@gmail.com>

---------

Signed-off-by: samay43 <samayrbhat43@gmail.com>
2026-08-26 17:57:36 +08:00
+7
Nolan EmirotGitHubblackpigletdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>Daniel Jiangcopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>dongqingccJoseph Antony VaikathClaude Opus 4.6peter woodmanPierluigi LenociXun Jiangdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>Lyndon-LiTiger Kaovilaicopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>Tiger Kaovilai
e33d8a3f84 docs(aws-plugin): update version (#9773)
Run the E2E test on kind / setup-test-matrix (push) Failing after 3s
e2e-test-kind.yaml / extract (push) Failing after 6s
Run the E2E test on kind / get-go-version (push) Failing after 7s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 8s
Main CI / get-go-version (push) Failing after 9s
Main CI / Build (push) Skipped
* docs(aws-plugin): update version

Signed-off-by: emirot <emirot.nolan@gmail.com>

* Add e2e test case for issue 7725

Signed-off-by: dongqingcc <dongqingcc@vmware.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* Add e2e test case for PR 9452

Signed-off-by: dongqingcc <dongqingcc@vmware.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* fix: lint permission issue (#9740)

* fix: lint permission issue

Signed-off-by: emirot <emirot.nolan@gmail.com>

* fix: lint permission issue

Signed-off-by: emirot <emirot.nolan@gmail.com>

* Set permissions to the actions

This commit update the actions  "Auto Assign Author", "Auto Label PRs",
and  "Auto Request Review"

Signed-off-by: Daniel Jiang <daniel.jiang@broadcom.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* Fix wildcard expansion when includes is empty and excludes has wildcards (#9684)

* Fix wildcard expansion when includes is empty and excludes has wildcards

When a Backup CR is applied via kubectl with empty includedNamespaces
and a wildcard in excludedNamespaces, ShouldExpandWildcards triggers
expansion. The empty includes expands to nil, but wildcardExpanded is
set to true, causing ShouldInclude to return false for all namespaces.

Populate expanded includes with all active namespaces when the original
includes was empty (meaning "include all") so that the wildcardExpanded
check does not falsely reject everything.

Signed-off-by: Joseph <jvaikath@redhat.com>

* Changelog

Signed-off-by: Joseph <jvaikath@redhat.com>

* Normalize empty includes to * instead of active namespaces list

This ensures consistent behavior between CLI and kubectl-apply paths
for Namespace CR inclusion when excludes contain wildcards.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Joseph <jvaikath@redhat.com>

* Move empty includes normalization to backup controller

Instead of normalizing empty IncludedNamespaces to ["*"] in the
collections layer's ExpandIncludesExcludes, do it earlier in
prepareBackupRequest. This ensures the spec is correct before any
downstream processing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Joseph <jvaikath@redhat.com>

* Update TestProcessBackupCompletions for wildcard normalization

Add IncludedNamespaces: []string{"*"} to all expected BackupSpec
structs, reflecting the new prepareBackupRequest normalization.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Joseph <jvaikath@redhat.com>

* Add checks around empty includenamespaces

Signed-off-by: Joseph <jvaikath@redhat.com>

* gofmt

Signed-off-by: Joseph <jvaikath@redhat.com>

---------

Signed-off-by: Joseph <jvaikath@redhat.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* update hashicorp/go-hclog and go-plugin to current version (#9613)

Signed-off-by: Peter Woodman <peter@shortbus.org>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* fix: honor -stderrthreshold when -logtostderr is true (default)

klog v2 defaults -logtostderr to true, which silently ignores the
-stderrthreshold flag — all log levels are unconditionally sent to
stderr. This makes it impossible for log-aggregation systems to filter
by severity.

Bump klog to v2.140.0 and opt into the fixed behavior by setting
legacy_stderr_threshold_behavior=false and stderrthreshold=INFO (which
preserves current output while letting users override via CLI flags).

Ref: kubernetes/klog#212, kubernetes/klog#432
Signed-off-by: Pierluigi Lenoci <pierluigilenoci@gmail.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* fix: add changelog and nolint explanation for CI

Add missing changelog entry for PR 9654 (fixes Changelog Check).
Add explanation to //nolint:errcheck directives (fixes nolintlint).

Signed-off-by: Pierluigi Lenoci <pierluigilenoci@gmail.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* Remove Restic code path from PodVolumeRestore.

Signed-off-by: Xun Jiang <xun.jiang@broadcom.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* Bump go.opentelemetry.io/otel from 1.40.0 to 1.41.0

Bumps [go.opentelemetry.io/otel](https://github.com/open-telemetry/opentelemetry-go) from 1.40.0 to 1.41.0.
- [Release notes](https://github.com/open-telemetry/opentelemetry-go/releases)
- [Changelog](https://github.com/open-telemetry/opentelemetry-go/blob/main/CHANGELOG.md)
- [Commits](https://github.com/open-telemetry/opentelemetry-go/compare/v1.40.0...v1.41.0)

---
updated-dependencies:
- dependency-name: go.opentelemetry.io/otel
  dependency-version: 1.41.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* Fix error in auto-request-review action

Per action.yml of the action, the token is required.
https://github.com/necojackarc/auto-request-review/blob/e89da1a8cd7c8c16d9de9c6e763290b6b0e3d424/action.yml#L8

Signed-off-by: Daniel Jiang <daniel.jiang@broadcom.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* fix go-releaser upload error

Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* add concurrency limit to go-releaser

Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* Bump go.opentelemetry.io/otel/sdk from 1.40.0 to 1.43.0 (#9692)

Bumps [go.opentelemetry.io/otel/sdk](https://github.com/open-telemetry/opentelemetry-go) from 1.40.0 to 1.43.0.
- [Release notes](https://github.com/open-telemetry/opentelemetry-go/releases)
- [Changelog](https://github.com/open-telemetry/opentelemetry-go/blob/main/CHANGELOG.md)
- [Commits](https://github.com/open-telemetry/opentelemetry-go/compare/v1.40.0...v1.43.0)

---
updated-dependencies:
- dependency-name: go.opentelemetry.io/otel/sdk
  dependency-version: 1.43.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* fix(lint): fix lint local

Signed-off-by: emirot <emirot.nolan@gmail.com>

* Apply suggestion from @blackpiglet

https://github.com/velero-io/velero/pull/9740/changes#r3151366281

Signed-off-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>

---------

Signed-off-by: emirot <emirot.nolan@gmail.com>
Signed-off-by: Daniel Jiang <daniel.jiang@broadcom.com>
Signed-off-by: Joseph <jvaikath@redhat.com>
Signed-off-by: Peter Woodman <peter@shortbus.org>
Signed-off-by: Pierluigi Lenoci <pierluigilenoci@gmail.com>
Signed-off-by: Xun Jiang <xun.jiang@broadcom.com>
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
Signed-off-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>
Co-authored-by: Daniel Jiang <daniel.jiang@broadcom.com>
Co-authored-by: Joseph Antony Vaikath <jvaikath@redhat.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: peter woodman <peter@shortbus.org>
Co-authored-by: Pierluigi Lenoci <pierluigilenoci@gmail.com>
Co-authored-by: Xun Jiang <xun.jiang@broadcom.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Lyndon-Li <lyonghui@vmware.com>
Co-authored-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* Bump github.com/moby/spdystream from 0.5.0 to 0.5.1 (#9734)

* Bump github.com/moby/spdystream from 0.5.0 to 0.5.1

Bumps [github.com/moby/spdystream](https://github.com/moby/spdystream) from 0.5.0 to 0.5.1.
- [Release notes](https://github.com/moby/spdystream/releases)
- [Commits](https://github.com/moby/spdystream/compare/v0.5.0...v0.5.1)

---
updated-dependencies:
- dependency-name: github.com/moby/spdystream
  dependency-version: 0.5.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix: run go mod tidy to update module files

Agent-Logs-Url: https://github.com/velero-io/velero/sessions/3537c5cb-5e31-405c-a79f-878bd146efa8

Co-authored-by: blackpiglet <59276555+blackpiglet@users.noreply.github.com>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Xun Jiang/Bruce Jiang <59276555+blackpiglet@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Daniel Jiang <daniel.jiang@broadcom.com>
Co-authored-by: Xun Jiang/Bruce Jiang <59276555+blackpiglet@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* fix docker hub push error

Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
Signed-off-by: emirot <emirot.nolan@gmail.com>

* updating aws plugin to a matching version

Signed-off-by: emirot <emirot.nolan@gmail.com>

---------

Signed-off-by: emirot <emirot.nolan@gmail.com>
Signed-off-by: dongqingcc <dongqingcc@vmware.com>
Signed-off-by: Daniel Jiang <daniel.jiang@broadcom.com>
Signed-off-by: Joseph <jvaikath@redhat.com>
Signed-off-by: Peter Woodman <peter@shortbus.org>
Signed-off-by: Pierluigi Lenoci <pierluigilenoci@gmail.com>
Signed-off-by: Xun Jiang <xun.jiang@broadcom.com>
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Lyndon-Li <lyonghui@vmware.com>
Signed-off-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>
Signed-off-by: Xun Jiang/Bruce Jiang <59276555+blackpiglet@users.noreply.github.com>
Co-authored-by: dongqingcc <dongqingcc@vmware.com>
Co-authored-by: Daniel Jiang <daniel.jiang@broadcom.com>
Co-authored-by: Joseph Antony Vaikath <jvaikath@redhat.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: peter woodman <peter@shortbus.org>
Co-authored-by: Pierluigi Lenoci <pierluigilenoci@gmail.com>
Co-authored-by: Xun Jiang <xun.jiang@broadcom.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Lyndon-Li <lyonghui@vmware.com>
Co-authored-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>
Co-authored-by: Xun Jiang/Bruce Jiang <59276555+blackpiglet@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Tiger Kaovilai <tkaovila@redhat.com>
2026-08-26 14:46:04 +08:00
acefa77d89 Fix testifylint require-error lint failure in node_agent_test.go
Co-authored-by: kaovilai <11228024+kaovilai@users.noreply.github.com>
2026-08-25 23:45:53 +00:00
2c6f45508c Report a measured zero incremental instead of erasing it (#10309)
Run the E2E test on kind / setup-test-matrix (push) Failing after 4s
e2e-test-kind.yaml / extract (push) Failing after 11s
Run the E2E test on kind / get-go-version (push) Failing after 12s
Run the E2E test on kind / build (push) Skipped
Run the E2E test on kind / run-e2e-test (push) Skipped
push.yml / extract (push) Failing after 7s
Main CI / get-go-version (push) Failing after 8s
Main CI / Build (push) Skipped
* Report a measured zero incremental instead of erasing it

A CBT incremental with an exactly zero delta -- nothing changed since
the parent -- was reported identically to a backup that moved the whole
device. `velero backup describe --details` printed only
"Moved data Size (bytes): 3221225472" with no incremental line, and
status.incrementalBytes was absent, for a run that transferred nothing.
The best possible CBT outcome displayed as the worst, and was
indistinguishable from a genuine full, a whole-device fallback, or a
backup predating incremental accounting.

The zero was being erased twice. Besides the API status fields,
datapath.BackupResult also carried omitempty, and that struct crosses a
JSON boundary from the data mover pod to the controller (see
micro_service_watcher.go), so the value was destroyed before the
controller could persist it. Every uploader always reports a figure
there, so 0 internally always means "transferred nothing" -- dropping
omitempty is sufficient and correct for that hop.

The API fields move to *int64 rather than just dropping omitempty. The
field shipped in v1.18.0-v1.18.2, so backups exist whose stored volume
info has no incrementalSize at all; with a plain int64 those unmarshal
to 0 and would render "Incremental data Size (bytes): 0", a false claim
of a perfect incremental on a run that never measured one. nil means not
measured, a pointer to 0 means measured zero. Both fields already carry
+optional, so the generated CRD schema is unchanged and no regeneration
is required.

Display gates relax from > 0 to != nil in all three places, including
volumesByPod.Add, whose signature takes *int64 now; the restore describer
passes nil, which is correct since restores measure no incremental.

Verified live: the same zero-delta scenario that reported <none> now
reports 0 and renders "Incremental data Size (bytes): 0", while an older
backup described with the new client still correctly prints no
incremental line at all.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
(cherry picked from commit 6c7aa9d588f6d5eab134d4ce19c92b838f45557c)
Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>

* gofmt: fix import ordering in backup_test.go

Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>

* Regenerate CRDs for IncrementalBytes pointer type

make update-crd was missed in the original commit. Regenerated with
the pinned controller-gen v0.16.5 to avoid unrelated version-annotation
churn across other CRDs.

Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>

* Add changelog for #10309

Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>

* Address review: make IncrementalBytes a pointer to preserve backward compat

Per Lyndon-Li's review on #10309: dropping omitempty on the plain int64
field breaks compatibility with a data mover from release-1.17 or
earlier that predates IncrementalBytes and never writes the key -- the
new controller would unmarshal a zero value ("nothing transferred")
instead of recognizing the field is simply absent ("not measured").

Switch to *int64 with omitempty restored:
- an old mover's omitted key unmarshals to nil ("not measured")
- a current mover's genuine zero still serializes the key, unmarshaling
  to a non-nil pointer to 0 ("measured zero")
- nonzero values work exactly as before
- an old controller can still unmarshal a numeric value from a new mover

pkg/controller/data_upload_controller.go and pod_volume_backup_controller.go
assign the wire-struct field directly to their already-*int64,omitempty
CRD status field instead of re-wrapping it with ptr.To, since both are
now the same pointer type.

Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>

* Fix CI: update marshal-fail test assertions for IncrementalBytes pointer

Both backup_micro_service_test.go files hardcoded the %v-formatted
zero-value BackupResult struct in an error-message assertion. Now that
IncrementalBytes is *int64, its zero value prints as <nil> instead of 0.

Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>

---------

Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-08-25 18:08:17 -04:00
Joseph Antony VaikathandGitHub e14ffe3e4c chore(deps): bump golang.org/x libs to fix CVEs (#10402)
Fixes:
- CVE-2026-56864, CVE-2026-56865: golang.org/x/mod v0.36.0 → v0.40.0
- CVE-2026-46600: golang.org/x/net v0.55.0 → v0.58.0
- CVE-2026-56852: golang.org/x/text v0.37.0 → v0.41.0

Transitive golang.org/x dependencies (crypto, sync, sys, term, tools)
updated accordingly to satisfy version constraints.

Signed-off-by: Joseph <jvaikath@redhat.com>
2026-08-25 15:55:56 -04:00
5b0aa81663 feat(cli): add velero client config set namespace-mode=auto (#10127)
* Issue #3194: Add velero client set-context-as-velero-namespace command

Saves the namespace of the current (or a specified) kubeconfig context
into the Velero client config file, so operational commands default to
it without requiring --namespace on every invocation.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Signed-off-by: lubronzhan <lubron.zhan@broadcom.com>

* Fix CI: rename changelog to PR number, add unit tests for coverage

- changelogs/unreleased must be named <pr-number>-<username>; rename
  from the 0000 placeholder to 10127 to satisfy hack/changelog-check.sh.
- Extract the command's logic into setContextAsVeleroNamespace so it's
  testable without triggering os.Exit via cmd.CheckError, and add unit
  tests covering: namespace read from context, context with no explicit
  namespace, overwriting an existing config value, and invalid
  kubeconfig path. Addresses 0% codecov patch coverage on the PR.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Signed-off-by: lubronzhan <lubron.zhan@broadcom.com>

* Move set-namespace-from-context under client config

Shubham suggested nesting the new command under `config` for
hierarchy consistency, and renaming it since the original
set-context-as-velero-namespace name was long and ambiguous. Moves
it to `velero client config set-namespace-from-context`, matching
the existing config get/set subcommands and my follow-up naming
suggestion on the review thread.

AI-Tool-Used: Claude Code
AI-Tool-Use-Level: Category 3 (Low)
AI-Code-Category: Category 1 (Production)
Signed-off-by: lubronzhan <lubron.zhan@broadcom.com>

* Replace set-namespace-from-context with namespace-mode=auto

kaovilai noted on #10127 that a one-shot command to snapshot the
kubecontext namespace becomes redundant once a config toggle can
resolve it dynamically, and isn't much simpler than the existing
`config set namespace=...` alternative.

Drop the dedicated set-namespace-from-context subcommand and instead
teach the client Factory to resolve the operational namespace from the
current kubeconfig context on every invocation when
`namespace-mode=auto` is set via the existing generic
`config set` command. Explicit --namespace flags and VELERO_NAMESPACE
still take precedence, so the new mode only changes behavior when
neither is set.

AI-Tool-Used: Claude Code
AI-Tool-Use-Level: Category 2 (Medium)
AI-Code-Category: Category 1 (Production)
Signed-off-by: lubronzhan <lubron.zhan@broadcom.com>

* Address PR review: doc, fallback test, t.Setenv

Resolve feedback from PR #10127 review 4966054980:
- Document how to disable namespace-mode=auto (namespace-mode=)
  and note the fallback to the static namespace, in namespace.md.
- Add a factory test covering the fallback to the stored/default
  namespace when kubeconfig namespace resolution fails.
- Switch the VELERO_NAMESPACE override test to t.Setenv, wrapped
  in a subtest so its cleanup runs before later tests execute.

AI-Tool-Used: Claude Code
AI-Tool-Use-Level: Category 2 (Medium)
AI-Code-Category: Category 2 (Non-Production)
Signed-off-by: lubronzhan <lubron.zhan@broadcom.com>

---------

Signed-off-by: lubronzhan <lubron.zhan@broadcom.com>
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-25 15:23:55 -04:00
Ali AsgharandGitHub 7fce37a0ac Fix e2e cache miss on force push by saving build artifacts explicitly (#9952)
* Fix e2e cache miss on force push by saving artifacts explicitly

actions/cache@v4 writes the cache in a post-job hook that runs after the
job reports completion. The run-e2e-test jobs (needs: build) start as
soon as build completes, before that post-hook save runs, so on a force
push -- where the github.sha-keyed cache has no prior entry -- they
deterministically miss the cache and fail with
'stat velero.tar: no such file or directory'.

Switch the build job's lookups to actions/cache/restore and add explicit
actions/cache/save steps at the end of the job (CLI, image, and MinIO),
so the cache is written before build reports done. The run-e2e-test
reads become actions/cache/restore.

Fixes #9927

Signed-off-by: alliasgher <alliasgher123@gmail.com>

* Add changelog for #9952

Signed-off-by: alliasgher <alliasgher123@gmail.com>

---------

Signed-off-by: alliasgher <alliasgher123@gmail.com>
2026-08-25 18:42:30 +00:00