add missing groups

This commit is contained in:
Tobias Powalowski 2022-05-04 19:47:23 +02:00
parent 10d97d1de5
commit 8d2ba11188
3 changed files with 8 additions and 0 deletions

View file

@ -35,6 +35,7 @@ if [[ "${_RUNNING_ARCH}" == "x86_64" ]]; then
_clean_container "${1}" 2>/dev/null _clean_container "${1}" 2>/dev/null
fi fi
_change_pacman_conf "${1}" || exit 1 _change_pacman_conf "${1}" || exit 1
_add_groups
_reproducibility "${1}" _reproducibility "${1}"
_set_hostname "${1}" || exit 1 _set_hostname "${1}" || exit 1
echo "Finished container setup in ${1} ." echo "Finished container setup in ${1} ."

View file

@ -31,6 +31,7 @@ if grep -q "^\[testing" /etc/pacman.conf; then
sed -i -e '/^#\[community-testing\]/ { n ; s/^#// }' "${1}/etc/pacman.conf" sed -i -e '/^#\[community-testing\]/ { n ; s/^#// }' "${1}/etc/pacman.conf"
sed -i -e 's:^#\[testing\]:\[testing\]:g' -e 's:^#\[community-testing\]:\[community-testing\]:g' "${1}/etc/pacman.conf" sed -i -e 's:^#\[testing\]:\[testing\]:g' -e 's:^#\[community-testing\]:\[community-testing\]:g' "${1}/etc/pacman.conf"
fi fi
_add_groups
_reproducibility "${1}" _reproducibility "${1}"
_set_hostname "${1}" || exit 1 _set_hostname "${1}" || exit 1
echo "Finished container setup in ${1} ." echo "Finished container setup in ${1} ."

View file

@ -187,3 +187,9 @@ _set_hostname() {
echo "Setting hostname to archboot ..." echo "Setting hostname to archboot ..."
echo 'archboot' > "${1}/etc/hostname" echo 'archboot' > "${1}/etc/hostname"
} }
_add_groups() {
grep -qw network /etc/group || groupadd network
grep -qw tss /etc/group || groupadd tss
grep -qw netdev /etc/group || groupadd netdev
}