mkosi.build: Only create groups if they don't exist yet

This commit is contained in:
Daan De Meyer 2021-01-09 17:41:16 +01:00
parent c3e2dc71de
commit 1e48ef3f5d

View File

@ -91,7 +91,7 @@ cd "$BUILDDIR"
ninja
if [ "$WITH_TESTS" = 1 ] ; then
for id in 1 2 3; do
groupadd -g $id testgroup$id || :
getent group $id > /dev/null || groupadd -g $id testgroup$id
done
ninja test