diff options
author | Vyacheslav Yurkov <v.yurkov@precitec.de> | 2022-06-01 21:30:11 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-06-04 11:28:23 +0100 |
commit | 366e7e620bb749a247a1f7288f0ed8cedd529ded (patch) | |
tree | cc3fded1fa0675411b7500ce70ae3e87d8ceead3 /meta | |
parent | 5fc131c5a91b056a173eab4cd04148fdfc297b8c (diff) | |
download | poky-366e7e620bb749a247a1f7288f0ed8cedd529ded.tar.gz |
files: respect overlayfs owner from lower layer
Permission model of overlayfs uses permissions/ownership from the upper
layer after mounting. Fix up UID/GID of the upper layer, when lower
layer already uses something custom.
(From OE-Core rev: b19b734ec3c031ee594229e728ee077cd58b34a9)
Signed-off-by: Vyacheslav Yurkov <v.yurkov@precitec.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/files/overlayfs-create-dirs.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/meta/files/overlayfs-create-dirs.sh b/meta/files/overlayfs-create-dirs.sh index 06c7587a6b..9954c34352 100644 --- a/meta/files/overlayfs-create-dirs.sh +++ b/meta/files/overlayfs-create-dirs.sh | |||
@@ -6,3 +6,6 @@ lowerdir=$1 | |||
6 | datamountpoint=$2 | 6 | datamountpoint=$2 |
7 | mkdir -p ${datamountpoint}/upper${lowerdir} | 7 | mkdir -p ${datamountpoint}/upper${lowerdir} |
8 | mkdir -p ${datamountpoint}/workdir${lowerdir} | 8 | mkdir -p ${datamountpoint}/workdir${lowerdir} |
9 | if [ -d "$lowerdir" ]; then | ||
10 | chown $(stat -c "%U:%G" ${lowerdir}) ${datamountpoint}/upper${lowerdir} | ||
11 | fi | ||