Repository navigation
Commit 2a59b59
initramfs: match overlay upper dir mode to lower root fs
overlayfs takes the merged directory metadata from the upper dir, not
the lower [1]. Since we were creating the upper with a hardcoded 0755,
every transient overlay showed 0755 for the merged directory, hiding
whatever mode the image committed.
This matters most for the merged root (root-transient) and /usr overlay.
With the previous commit in ostree-ext copying /usr metadata to the root
commit, images can now ship / as 0555. The hardcoded 0755 upper masked
that after the overlay.
Create the upper dir with the lower root's mode so the merged view keeps
the image permissions. Persistent overlays (/etc) keep the previous
hard-coded 0755. This goes further than composefs-rs so that transient
roots match the committed metadata.
Assisted-by: llm
Signed-off-by: Rolv Apneseth <rolv.apneseth@gmail.com>
[1]: composefs/composefs-rs#2871 parent a417a15 commit 2a59b59
1 file changed
Lines changed: 9 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
270 | 270 | | |
271 | 271 | | |
272 | 272 | | |
273 | | - | |
274 | | - | |
275 | | - | |
276 | | - | |
| 273 | + | |
| 274 | + | |
277 | 275 | | |
278 | 276 | | |
279 | 277 | | |
280 | 278 | | |
281 | 279 | | |
| 280 | + | |
282 | 281 | | |
283 | 282 | | |
284 | | - | |
| 283 | + | |
285 | 284 | | |
286 | 285 | | |
287 | 286 | | |
| |||
306 | 305 | | |
307 | 306 | | |
308 | 307 | | |
309 | | - | |
| 308 | + | |
310 | 309 | | |
311 | 310 | | |
312 | 311 | | |
| |||
333 | 332 | | |
334 | 333 | | |
335 | 334 | | |
336 | | - | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
337 | 339 | | |
338 | 340 | | |
339 | 341 | | |
| |||
0 commit comments