mirror of
https://github.com/kemko/nomad.git
synced 2026-01-04 01:15:43 +03:00
volume_hook: Loosen validation in host volume prep
This commit is contained in:
committed by
Tim Gross
parent
7d044a340f
commit
01ff8960b5
@@ -57,8 +57,10 @@ func (h *volumeHook) hostVolumeMountConfigurations(taskMounts []*structs.VolumeM
|
||||
for _, m := range taskMounts {
|
||||
req, ok := taskVolumesByAlias[m.Volume]
|
||||
if !ok {
|
||||
// Should never happen unless we misvalidated on job submission
|
||||
return nil, fmt.Errorf("No group volume declaration found named: %s", m.Volume)
|
||||
// This function receives only the task volumes that are of type Host,
|
||||
// if we can't find a group volume then we assume the mount is for another
|
||||
// type.
|
||||
continue
|
||||
}
|
||||
|
||||
// This is a defensive check, but this function should only ever receive
|
||||
|
||||
Reference in New Issue
Block a user