Multiple fixes
This commit is contained in:
parent
845d135b53
commit
ca3b27f70b
@ -43,7 +43,7 @@ while getopts "hU:P:H:D:FIZ:S:" opt; do
|
|||||||
done
|
done
|
||||||
shift $((OPTIND-1))
|
shift $((OPTIND-1))
|
||||||
|
|
||||||
if [[ $(ls nasbeery.conf) ]]; then
|
if [ -f nasbeery.conf ]; then
|
||||||
source nasbeery.conf
|
source nasbeery.conf
|
||||||
else
|
else
|
||||||
cat << EOF > nasbeery.conf
|
cat << EOF > nasbeery.conf
|
||||||
@ -82,6 +82,11 @@ Pin: release a=bullseye-backports
|
|||||||
Pin-Priority: 900
|
Pin-Priority: 900
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
grep contrib /etc/apt/sources.list
|
||||||
|
if [ $? -gt 0 ]; then
|
||||||
|
sed -i "s/main/main contrib non-free/g" /etc/apt/sources.list
|
||||||
|
fi
|
||||||
|
|
||||||
# update system and install packages
|
# update system and install packages
|
||||||
echo "Updating package lists"
|
echo "Updating package lists"
|
||||||
apt -qq update
|
apt -qq update
|
||||||
@ -183,7 +188,7 @@ useradd $USERNAME
|
|||||||
echo "$USERNAME:$PASSWORD" | chpasswd
|
echo "$USERNAME:$PASSWORD" | chpasswd
|
||||||
smbpasswd -x $USERNAME
|
smbpasswd -x $USERNAME
|
||||||
(echo $PASSWORD; echo $PASSWORD) | smbpasswd -a $USERNAME
|
(echo $PASSWORD; echo $PASSWORD) | smbpasswd -a $USERNAME
|
||||||
usermod -aG $USERNAME
|
usermod -aG sudo $USERNAME
|
||||||
|
|
||||||
echo "Writing cockpit configuration"
|
echo "Writing cockpit configuration"
|
||||||
cat << EOF | tee -i /etc/cockpit/zfs/config.json
|
cat << EOF | tee -i /etc/cockpit/zfs/config.json
|
||||||
|
Loading…
Reference in New Issue
Block a user