install.sh aktualisiert
This commit is contained in:
parent
4359f86e56
commit
0cd86abf60
@ -4,7 +4,13 @@ set -e
|
|||||||
|
|
||||||
# on fresh install remove cdrom-repo and install sudo if not available
|
# on fresh install remove cdrom-repo and install sudo if not available
|
||||||
which sudo >/dev/null 2>&1 || su -c "sed -i '/cdrom/d' /etc/apt/sources.list ; apt update ; apt -y install sudo"
|
which sudo >/dev/null 2>&1 || su -c "sed -i '/cdrom/d' /etc/apt/sources.list ; apt update ; apt -y install sudo"
|
||||||
id | grep -q '(sudo)' || su -c "/usr/sbin/usermod -a -G sudo ${USER}"
|
# add user to sudo group it not
|
||||||
|
if ! id | grep -q '(sudo)'
|
||||||
|
then
|
||||||
|
su -c "/usr/sbin/usermod -a -G sudo ${USER}"
|
||||||
|
# use sudo group without
|
||||||
|
exec sg sudo "newgrp `id -gn`"
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
sudo apt-get -y install ansible git
|
sudo apt-get -y install ansible git
|
||||||
|
Loading…
Reference in New Issue
Block a user