Merge mounts in FillDefault based on mountPoint instead of location #4046
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Based on findings in #4042 (comment)
The template merge code already merged mounts correctly based on
mountPoint
, butFillDefault
still merged based onlocation
1.Using
master
without this PR:So template merging has (correctly) dropped mounting the
/baz
location because the/bar
mount point was already fully defined.And then the
/foo
mount point has been incorrectly dropped because it shared a mount location with the/bar
mount point.This is fixed in this PR:
So template merging is unchanged and has correctly removed the
/baz
location, but both the/foo
and/bar
mount points have been correctly preserved.Footnotes
The whole
FillDefault()
logic should be implemented via template merging, but that will be a bigger job. ↩