Incorporated changes for 1.3.1
This commit is contained in:
@@ -2,11 +2,12 @@
|
||||
|
||||
# terminal-setup.sh
|
||||
# OpenDRS Online Maintenance Tracking System
|
||||
# Copyright (C) 2021 Rod Wright
|
||||
# Copyright (C) 2022 Rod Wright
|
||||
|
||||
# SPDX-License-Identifier: GPL-2.0
|
||||
|
||||
current_user=`whoami`
|
||||
current_login=`who am i | awk '{print $1}'`
|
||||
if [ "$current_user" != "root" ]
|
||||
then
|
||||
echo "You must have root privileges to run this setup."
|
||||
@@ -23,24 +24,31 @@ echo ""
|
||||
echo "You should have already completed the following steps:"
|
||||
echo ""
|
||||
echo "1. Created a Raspberry Pi OS Lite SD card from the latest release."
|
||||
echo "2. Installed the card in a Raspberry Pi, booted it, and logged in as pi."
|
||||
echo ""
|
||||
echo "2. Installed the card in a Raspberry Pi, booted it, and completed"
|
||||
echo " initial configuration."
|
||||
echo ""
|
||||
echo "3. Ran sudo raspi-config and :"
|
||||
echo " a. Set locale, timezone, keyboard layout, and wifi country under"
|
||||
echo " Localisation Options. IMPORTANT: Do this first before setting"
|
||||
echo " any passwords. Changing keyboard types usually changes character"
|
||||
echo " mappings, meaning your password after the change may not be what"
|
||||
echo " it was before the change."
|
||||
echo " b. Set a strong password for the pi user."
|
||||
echo " c. Set hostname and, if accessing a network through wifi, the SSID and"
|
||||
echo " passphrase under Network Options."
|
||||
echo " d. Enable SSH under Interfacing Options."
|
||||
echo " e. Set overscan as required to get rid of any black borders around the"
|
||||
echo " edge of the display."
|
||||
echo " f. Reboot when prompted and logged back in as pi."
|
||||
echo "4. Transferred the OpenDRS distribution package to /home/pi on the"
|
||||
echo " a. Set locale, timezone, and WLAN Country under"
|
||||
echo " Localisation Options. "
|
||||
echo ""
|
||||
echo " b. Set hostname and Boot / Auto Login to Console under System Options."
|
||||
echo ""
|
||||
echo " c. If accessing a network through wifi, the Wireless LAN SSID"
|
||||
echo " and passphrase under System Options."
|
||||
echo ""
|
||||
echo " d. Enable SSH under Interface Options."
|
||||
echo ""
|
||||
echo " e. Set underscan as required under Display Options to get rid of any"
|
||||
echo " black borders around the edge of the display."
|
||||
echo ""
|
||||
echo " f. Reboot when prompted and logged back in as $current_login."
|
||||
echo ""
|
||||
echo "4. Transferred the OpenDRS distribution package to /home/$current_login on the"
|
||||
echo " Raspberry Pi and extracted it."
|
||||
echo "5. Changed directory to RPiSetup in the extracted distribution directory."
|
||||
echo ""
|
||||
echo ""
|
||||
echo "If you have completed these steps, press enter to continue. If not,"
|
||||
echo -n "press ctrl-c to quit."
|
||||
read continueok
|
||||
@@ -93,7 +101,7 @@ apt install -y --no-install-recommends xorg openbox chromium-browser
|
||||
apt install -y cups libcups2-dev cmake
|
||||
apt install -y webmin
|
||||
addgroup lpadmin
|
||||
usermod -a -G lpadmin pi
|
||||
usermod -a -G lpadmin $current_login
|
||||
systemctl enable getty@tty1.service
|
||||
service cups-browsed stop
|
||||
systemctl disable cups-browsed.service
|
||||
@@ -121,7 +129,7 @@ echo ""
|
||||
echo ""
|
||||
echo ""
|
||||
echo ""
|
||||
cloneuser `who am i | awk '{print $1}'` customer
|
||||
cloneuser $current_login customer
|
||||
mkdir -p /home/customer/.config/openbox
|
||||
cp home/customer/.profile /home/customer
|
||||
cp home/customer/.config/openbox/rc.xml /home/customer/.config/openbox
|
||||
@@ -160,10 +168,10 @@ echo ""
|
||||
echo "$conftype configuration is now complete. "
|
||||
echo ""
|
||||
echo ""
|
||||
echo "It is highly recommended that after rebooting, you run ssh pi@$HOSTNAME"
|
||||
echo "It is highly recommended that after rebooting, you run ssh $current_login@$HOSTNAME"
|
||||
echo "from another computer on the network, then create new users for"
|
||||
echo "yourself and any other administrators using the cloneuser command"
|
||||
echo "(cloneuser pi <new username>)."
|
||||
echo "any other administrators using the cloneuser command"
|
||||
echo "(cloneuser $current_login <new username>)."
|
||||
echo ""
|
||||
echo ""
|
||||
echo "Terminal setup complete."
|
||||
|
||||
Reference in New Issue
Block a user