lamp.sh: Only create systemd users if systemd is not already present

Signed-off-by: thecalcaholic <6317548+theCalcaholic@users.noreply.github.com>
This commit is contained in:
thecalcaholic 2022-09-28 22:05:54 +02:00
parent f3292624eb
commit 9076b3599f
No known key found for this signature in database
GPG Key ID: 3510056072886A8F

View File

@ -37,11 +37,13 @@ install()
apache2ctl -V || true
# Create systemd users to keep uids persistent between containers
addgroup --quiet --system systemd-journal
adduser --quiet -u 180 --system --group --no-create-home --home /run/systemd \
id -u systemd-resolve || {
addgroup --quiet --system systemd-journal
adduser --quiet -u 180 --system --group --no-create-home --home /run/systemd \
--gecos "systemd Network Management" systemd-network
adduser --quiet -u 181 --system --group --no-create-home --home /run/systemd \
adduser --quiet -u 181 --system --group --no-create-home --home /run/systemd \
--gecos "systemd Resolver" systemd-resolve
}
install_with_shadow_workaround --no-install-recommends systemd
$APTINSTALL -t $RELEASE php${PHPVER} php${PHPVER}-curl php${PHPVER}-gd php${PHPVER}-fpm php${PHPVER}-cli php${PHPVER}-opcache \
php${PHPVER}-mbstring php${PHPVER}-xml php${PHPVER}-zip php${PHPVER}-fileinfo php${PHPVER}-ldap \