diff --git a/.changelog/10840.txt b/.changelog/10840.txt new file mode 100644 index 000000000..100676693 --- /dev/null +++ b/.changelog/10840.txt @@ -0,0 +1,3 @@ +```release-note:bug +csi: Fixed a bug where volume secrets were not used for creating snapshots. +``` diff --git a/nomad/csi_endpoint.go b/nomad/csi_endpoint.go index f642441a7..30a223cc3 100644 --- a/nomad/csi_endpoint.go +++ b/nomad/csi_endpoint.go @@ -1124,7 +1124,7 @@ func (v *CSIVolume) CreateSnapshot(args *structs.CSISnapshotCreateRequest, reply cReq := &cstructs.ClientCSIControllerCreateSnapshotRequest{ ExternalSourceVolumeID: vol.ExternalID, Name: snap.Name, - Secrets: snap.Secrets, + Secrets: vol.Secrets, Parameters: snap.Parameters, } cReq.PluginID = plugin.ID