mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-03 09:22:44 +00:00
update mountpath of volume after migration
This commit is contained in:
parent
fea6b0d50c
commit
a5189d8bd1
@ -199,9 +199,15 @@ func (b flockerBuilder) SetUpAt(dir string, fsGroup *int64) error {
|
|||||||
if err := b.updateDatasetPrimary(datasetID, primaryUUID); err != nil {
|
if err := b.updateDatasetPrimary(datasetID, primaryUUID); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
newState, err := b.client.GetDatasetState(datasetID)
|
||||||
|
if err != nil {
|
||||||
|
return fmt.Errorf("The volume '%s' migrated unsuccessfully.", datasetID)
|
||||||
|
}
|
||||||
|
b.flocker.path = newState.Path
|
||||||
|
} else {
|
||||||
|
b.flocker.path = s.Path
|
||||||
}
|
}
|
||||||
|
|
||||||
b.flocker.path = s.Path
|
|
||||||
volumeutil.SetReady(b.getMetaDir())
|
volumeutil.SetReady(b.getMetaDir())
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user