teams/cloud/container: create dotfiles under root folder with systemd-tmpfiles

Since`rootfiles` now uses systemd-tmpfiles to install dotfiles under
root folder instead of copying.
This commit is contained in:
jackyzy823
2025-11-27 22:02:13 +08:00
parent 093f4032b7
commit 0996328b7c
2 changed files with 13 additions and 0 deletions
+7
View File
@@ -219,6 +219,13 @@ chmod 600 /root/.ssh/authorized_keys
chown -R root:root /root/.ssh chown -R root:root /root/.ssh
fi fi
# https://bugzilla.redhat.com/show_bug.cgi?id=2356069
if [[ "$kiwi_profiles" == *"Container"* ]] && [[ "$kiwi_profiles" != *"Init"* ]]; then
if [[ -f /usr/lib/tmpfiles.d/rootfiles.conf ]]; then
systemd-tmpfiles --create /usr/lib/tmpfiles.d/rootfiles.conf
fi
fi
if [[ "$kiwi_profiles" == *"Container"* ]] || [[ "$kiwi_profiles" == *"FEX"* ]]; then if [[ "$kiwi_profiles" == *"Container"* ]] || [[ "$kiwi_profiles" == *"FEX"* ]]; then
# Set install langs macro so that new rpms that get installed will # Set install langs macro so that new rpms that get installed will
# only install langs that we limit it to. # only install langs that we limit it to.
+6
View File
@@ -295,4 +295,10 @@
<package name="systemd-resolved"/> <package name="systemd-resolved"/>
<package name="xkeyboard-config"/> <package name="xkeyboard-config"/>
</packages> </packages>
<packages type="bootstrap" profiles="Container-Base-Generic-Minimal,Container-Base-Generic,Container-Toolbox">
<package name="systemd-standalone-tmpfiles"/>
</packages>
<packages type="uninstall" profiles="Container-Base-Generic-Minimal,Container-Base-Generic,Container-Toolbox">
<package name="systemd-standalone-tmpfiles"/>
</packages>
</image> </image>