infra/image: Use SYS_ADMIN capability for server deployment

This adds the capabilities SYS_ADMIN and SYSLOG to the container_create
call in build.sh as long as server deployment has been enabled.

The privileged option has been removed as it is no longer needed.

The hostnamectl-wrapper for the container has been removed as it is no
longer needed.
This commit is contained in:
Thomas Woerner
2024-12-02 15:01:20 +01:00
parent 489f4d5784
commit 4c3f4e6f7d
5 changed files with 9 additions and 25 deletions

View File

@@ -13,12 +13,6 @@ dnf --assumeyes install \
hostname; \
rm -rf /var/cache/dnf/;
# Prepare for basic ipa-server-install in container
# Address failing nis-domainname.service in the ipa-client-install step
RUN mv /usr/bin/nisdomainname /usr/bin/nisdomainname.orig
ADD utils/hostnamectl-wrapper /usr/bin/nisdomainname
RUN chmod a+rx /usr/bin/nisdomainname
RUN (cd /lib/systemd/system/; \
if [ -e dbus-broker.service ] && [ ! -e dbus.service ]; then \
ln -s dbus-broker.service dbus.service; \