mirror of
https://github.com/vmware-tanzu/velero.git
synced 2026-08-04 14:26:07 +00:00
Merge pull request #10144 from Lyndon-Li/empty-sa-namespace-for-get-changed-blocks
Run the E2E test on kind / setup-test-matrix (push) Successful in 4s
e2e-test-kind.yaml / extract (push) Failing after 11s
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) Successful in 11s
Main CI / get-go-version (push) Successful in 12s
Main CI / Build (push) Failing after 38s
Run the E2E test on kind / setup-test-matrix (push) Successful in 4s
e2e-test-kind.yaml / extract (push) Failing after 11s
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) Successful in 11s
Main CI / get-go-version (push) Successful in 12s
Main CI / Build (push) Failing after 38s
Empty sa namespace when secret is empty for getChangedBlocks
This commit is contained in:
@@ -116,6 +116,12 @@ func (s *ServiceImpl) GetChangedBlocks(ctx context.Context, snapshot string, cha
|
||||
return err
|
||||
}
|
||||
|
||||
saNamespace := ""
|
||||
if s.SAName != "" {
|
||||
// The SA is created in the same namespace as Velero server. vsNamespace is the namespace of Velero server.
|
||||
saNamespace = s.vsNamespace
|
||||
}
|
||||
|
||||
args := iterator.Args{
|
||||
SnapshotName: snapshot,
|
||||
PrevSnapshotID: changeID,
|
||||
@@ -126,7 +132,7 @@ func (s *ServiceImpl) GetChangedBlocks(ctx context.Context, snapshot string, cha
|
||||
|
||||
Clients: clients,
|
||||
Namespace: s.vsNamespace,
|
||||
SANamespace: s.vsNamespace,
|
||||
SANamespace: saNamespace,
|
||||
SAName: s.SAName,
|
||||
TokenExpirySecs: iterator.DefaultTokenExpirySeconds,
|
||||
MaxResults: 0, // If 0 then the CSI driver decides the value.
|
||||
|
||||
Reference in New Issue
Block a user