From 53700e72902179433eec05644e5ec2d9426b3b2e Mon Sep 17 00:00:00 2001 From: Igor Pecovnik Date: Sat, 31 Aug 2024 23:22:27 +0200 Subject: [PATCH 1/5] Enable support for adjusting SSH server --- lib/armbian-configng/config.ng.functions.sh | 64 ++++++++- lib/armbian-configng/config.ng.jobs.json | 143 +++++++++++++++++++- 2 files changed, 200 insertions(+), 7 deletions(-) diff --git a/lib/armbian-configng/config.ng.functions.sh b/lib/armbian-configng/config.ng.functions.sh index f5385b9cb..67ec9498b 100644 --- a/lib/armbian-configng/config.ng.functions.sh +++ b/lib/armbian-configng/config.ng.functions.sh @@ -82,7 +82,6 @@ function set_header_remove() { } - module_options+=( ["check_if_installed,author"]="Igor Pecovnik" ["check_if_installed,ref_link"]="" @@ -96,12 +95,65 @@ module_options+=( # function check_if_installed (){ - local DPKG_Status="$(dpkg -s "$1" 2>/dev/null | awk -F": " '/^Status/ {print $2}')" - if [[ "X${DPKG_Status}" = "X" || "${DPKG_Status}" = *deinstall* ]]; then - return 1 - else - return 0 + local DPKG_Status="$(dpkg -s "$1" 2>/dev/null | awk -F": " '/^Status/ {print $2}')" + if [[ "X${DPKG_Status}" = "X" || "${DPKG_Status}" = *deinstall* ]]; then + return 1 + else + return 0 + fi + +} + + +module_options+=( +["update_skel,author"]="Igor Pecovnik" +["update_skel,ref_link"]="" +["update_skel,feature"]="update_skel" +["update_skel,desc"]="Update the /etc/skel files in users directories" +["update_skel,example"]="update_skel" +["update_skel,status"]="Active" +) +# +# check dpkg status of $1 -- currently only 'not installed at all' case caught +# +function update_skel (){ + + getent passwd | + while IFS=: read -r username x uid gid gecos home shell + do + if [ ! -d "$home" ] || [ "$username" == 'root' ] || [ "$uid" -lt 1000 ] + then + continue + fi + tar -C /etc/skel/ -cf - . | su - "$username" -c "tar --skip-old-files -xf -" + done + +} + + +module_options+=( +["qr_code,author"]="Igor Pecovnik" +["qr_code,ref_link"]="" +["qr_code,feature"]="qr_code" +["qr_code,desc"]="Show or generate QR code for Google OTP" +["qr_code,example"]="qr_code generate" +["qr_code,status"]="Active" +) +# +# check dpkg status of $1 -- currently only 'not installed at all' case caught +# +function qr_code (){ + + clear + if [[ "$1" == "generate" ]]; then + google-authenticator -t -d -f -r 3 -R 30 -W -q + cp /root/.google_authenticator /etc/skel + update_skel fi + export TOP_SECRET=$(head -1 /root/.google_authenticator) + qrencode -m 2 -d 9 -8 -t ANSI256 "otpauth://totp/test?secret=$TOP_SECRET" + echo -e '\nScan QR code with your OTP application on mobile phone\n' + read -n 1 -s -r -p "Press any key to continue" } diff --git a/lib/armbian-configng/config.ng.jobs.json b/lib/armbian-configng/config.ng.jobs.json index f978e5853..48da20f0c 100644 --- a/lib/armbian-configng/config.ng.jobs.json +++ b/lib/armbian-configng/config.ng.jobs.json @@ -229,8 +229,149 @@ "src_reference": "", "author": "", "condition": "check_if_installed avahi-daemon" + }, + { + "id": "N12", + "description": "Reconfigure OpenSSH daemon (secure shell)", + "sub": [ + { + "id": "SSH01", + "description": "Disable root login", + "command": [ + "sed -i \"s|^#\\?PermitRootLogin.*|PermitRootLogin no|\" /etc/ssh/sshd_config", + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q '^PermitRootLogin yes' /etc/ssh/sshd_config" + }, + { + "id": "SSH02", + "description": "Enable root login", + "command": [ + "sed -i \"s/^#\\?PermitRootLogin.*/PermitRootLogin yes/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q '^PermitRootLogin no' /etc/ssh/sshd_config" + }, + { + "id": "SSH03", + "description": "Disable password login", + "command": [ + "sed -i \"s/^#\\?PasswordAuthentication.*/PasswordAuthentication no/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PasswordAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "SSH04", + "description": "Enable password login", + "command": [ + "sed -i \"s/^#\\?PasswordAuthentication.*/PasswordAuthentication yes/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PasswordAuthentication no' /etc/ssh/sshd_config" + }, + { + "id": "SSH05", + "description": "Disable Public key authentication login", + "command": [ + "sed -i \"s/^#\\?PubkeyAuthentication.*/PubkeyAuthentication no/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PubkeyAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "SSH06", + "description": "Enable Public key authentication login", + "command": [ + "sed -i \"s/^#\\?PubkeyAuthentication.*/PubkeyAuthentication yes/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PubkeyAuthentication no' /etc/ssh/sshd_config" + }, + { + "id": "SSH07", + "description": "Disable OTP authentication", + "command": [ + "clear", + "! check_if_installed libpam-google-authenticator && ! check_if_installed qrencode || debconf-apt-progress -- apt-get -y purge libpam-google-authenticator qrencode", + "sed -i \"s/^#\\?ChallengeResponseAuthentication.*/ChallengeResponseAuthentication no/\" /etc/ssh/sshd_config || sed -i \"0,/KbdInteractiveAuthentication/s//ChallengeResponseAuthentication yes/\" /etc/ssh/sshd_config" , + "sed -i '/^auth required pam_google_authenticator.so nullok/ d' /etc/pam.d/sshd", + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'ChallengeResponseAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "SSH08", + "description": "Enable OTP authentication", + "command": [ + "check_if_installed libpam-google-authenticator || debconf-apt-progress -- apt-get -y install libpam-google-authenticator", + "check_if_installed qrencode || debconf-apt-progress -- apt-get -y install qrencode", + "sed -i \"s/^#\\?ChallengeResponseAuthentication.*/ChallengeResponseAuthentication yes/\" /etc/ssh/sshd_config || sed -i $'/KbdInteractiveAuthentication/{iChallengeResponseAuthentication yes\\n:a;n;ba}' /etc/ssh/sshd_config" , + "sed -n -i '/password updating/{p;:a;N;/@include common-password/!ba;s/.*\\n/auth required pam_google_authenticator.so nullok\\nauth required pam_permit.so\\n/};p' /etc/pam.d/sshd", + "[ ! -f /root/.google_authenticator ] && qr_code generate", + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "! check_if_installed libpam-google-authenticator || ! check_if_installed qrencode || grep -q '^ChallengeResponseAuthentication no' /etc/ssh/sshd_config || ! grep -q 'ChallengeResponseAuthentication' /etc/ssh/sshd_config" + }, + { + "id": "SSH09", + "description": "Generate new OTP authentication QR code", + "command": [ + "qr_code generate" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q '^ChallengeResponseAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "SSH10", + "description": "Show OTP authentication QR code", + "command": [ + "qr_code" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "Igor Pecovnik", + "condition": "grep -q '^ChallengeResponseAuthentication yes' /etc/ssh/sshd_config && [ -f /root/.google_authenticator ]" + } + ] } - ] + ] }, { "id": "Localisation", From 633df341db226521f76021202de78aebc148ff16 Mon Sep 17 00:00:00 2001 From: Igor Pecovnik Date: Sun, 1 Sep 2024 07:38:21 +0200 Subject: [PATCH 2/5] Add bits to README and move to system section --- README.md | 3 +- lib/armbian-configng/config.ng.jobs.json | 282 +++++++++++------------ 2 files changed, 142 insertions(+), 143 deletions(-) diff --git a/README.md b/README.md index f0da46a02..1b5a167e2 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,8 @@ sudo armbian-config - **S03** - Edit the boot environment - **S04** - Install Linux headers - **S05** - Remove Linux headers - + - **S06** - Install to internal storage + - **S07** - Manage SSH login options - ## **Network** - **N00** - Install Bluetooth support diff --git a/lib/armbian-configng/config.ng.jobs.json b/lib/armbian-configng/config.ng.jobs.json index 24de72be8..c651f9f21 100644 --- a/lib/armbian-configng/config.ng.jobs.json +++ b/lib/armbian-configng/config.ng.jobs.json @@ -75,6 +75,145 @@ "src_reference": "", "author": "https://github.com/igorpecovnik", "condition": "[[ -n $(ls /sbin/armbian-install) ]]" + }, + { + "id": "S07", + "description": "Manage SSH login options", + "sub": [ + { + "id": "S08", + "description": "Disable root login", + "command": [ + "sed -i \"s|^#\\?PermitRootLogin.*|PermitRootLogin no|\" /etc/ssh/sshd_config", + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q '^PermitRootLogin yes' /etc/ssh/sshd_config" + }, + { + "id": "S09", + "description": "Enable root login", + "command": [ + "sed -i \"s/^#\\?PermitRootLogin.*/PermitRootLogin yes/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q '^PermitRootLogin no' /etc/ssh/sshd_config" + }, + { + "id": "S10", + "description": "Disable password login", + "command": [ + "sed -i \"s/^#\\?PasswordAuthentication.*/PasswordAuthentication no/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PasswordAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "S11", + "description": "Enable password login", + "command": [ + "sed -i \"s/^#\\?PasswordAuthentication.*/PasswordAuthentication yes/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PasswordAuthentication no' /etc/ssh/sshd_config" + }, + { + "id": "S12", + "description": "Disable Public key authentication login", + "command": [ + "sed -i \"s/^#\\?PubkeyAuthentication.*/PubkeyAuthentication no/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PubkeyAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "S13", + "description": "Enable Public key authentication login", + "command": [ + "sed -i \"s/^#\\?PubkeyAuthentication.*/PubkeyAuthentication yes/\" /etc/ssh/sshd_config" , + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'PubkeyAuthentication no' /etc/ssh/sshd_config" + }, + { + "id": "S14", + "description": "Disable OTP authentication", + "command": [ + "clear", + "! check_if_installed libpam-google-authenticator && ! check_if_installed qrencode || debconf-apt-progress -- apt-get -y purge libpam-google-authenticator qrencode", + "sed -i \"s/^#\\?ChallengeResponseAuthentication.*/ChallengeResponseAuthentication no/\" /etc/ssh/sshd_config || sed -i \"0,/KbdInteractiveAuthentication/s//ChallengeResponseAuthentication yes/\" /etc/ssh/sshd_config" , + "sed -i '/^auth required pam_google_authenticator.so nullok/ d' /etc/pam.d/sshd", + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q 'ChallengeResponseAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "S15", + "description": "Enable OTP authentication", + "command": [ + "check_if_installed libpam-google-authenticator || debconf-apt-progress -- apt-get -y install libpam-google-authenticator", + "check_if_installed qrencode || debconf-apt-progress -- apt-get -y install qrencode", + "sed -i \"s/^#\\?ChallengeResponseAuthentication.*/ChallengeResponseAuthentication yes/\" /etc/ssh/sshd_config", + "sed -i $'/KbdInteractiveAuthentication/{iChallengeResponseAuthentication yes\\n:a;n;ba}' /etc/ssh/sshd_config || sed -n -i '/password updating/{p;:a;N;/@include common-password/!ba;s/.*\\n/auth required pam_google_authenticator.so nullok\\nauth required pam_permit.so\\n/};p' /etc/pam.d/sshd", + "[ ! -f /root/.google_authenticator ] && qr_code generate", + "systemctl restart sshd.service" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "! check_if_installed libpam-google-authenticator || ! check_if_installed qrencode || grep -q '^ChallengeResponseAuthentication no' /etc/ssh/sshd_config || ! grep -q 'ChallengeResponseAuthentication' /etc/ssh/sshd_config" + }, + { + "id": "S16", + "description": "Generate new OTP authentication QR code", + "command": [ + "qr_code generate" + ], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "", + "condition": "grep -q '^ChallengeResponseAuthentication yes' /etc/ssh/sshd_config" + }, + { + "id": "S17", + "description": "Show OTP authentication QR code", + "command": ["qr_code"], + "status": "Active", + "doc_link": "", + "src_reference": "", + "author": "Igor Pecovnik", + "condition": "grep -q '^ChallengeResponseAuthentication yes' /etc/ssh/sshd_config && [ -f /root/.google_authenticator ]" + } + ] } ] @@ -242,149 +381,8 @@ "src_reference": "", "author": "", "condition": "check_if_installed avahi-daemon" - }, - { - "id": "N12", - "description": "Reconfigure OpenSSH daemon (secure shell)", - "sub": [ - { - "id": "SSH01", - "description": "Disable root login", - "command": [ - "sed -i \"s|^#\\?PermitRootLogin.*|PermitRootLogin no|\" /etc/ssh/sshd_config", - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q '^PermitRootLogin yes' /etc/ssh/sshd_config" - }, - { - "id": "SSH02", - "description": "Enable root login", - "command": [ - "sed -i \"s/^#\\?PermitRootLogin.*/PermitRootLogin yes/\" /etc/ssh/sshd_config" , - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q '^PermitRootLogin no' /etc/ssh/sshd_config" - }, - { - "id": "SSH03", - "description": "Disable password login", - "command": [ - "sed -i \"s/^#\\?PasswordAuthentication.*/PasswordAuthentication no/\" /etc/ssh/sshd_config" , - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q 'PasswordAuthentication yes' /etc/ssh/sshd_config" - }, - { - "id": "SSH04", - "description": "Enable password login", - "command": [ - "sed -i \"s/^#\\?PasswordAuthentication.*/PasswordAuthentication yes/\" /etc/ssh/sshd_config" , - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q 'PasswordAuthentication no' /etc/ssh/sshd_config" - }, - { - "id": "SSH05", - "description": "Disable Public key authentication login", - "command": [ - "sed -i \"s/^#\\?PubkeyAuthentication.*/PubkeyAuthentication no/\" /etc/ssh/sshd_config" , - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q 'PubkeyAuthentication yes' /etc/ssh/sshd_config" - }, - { - "id": "SSH06", - "description": "Enable Public key authentication login", - "command": [ - "sed -i \"s/^#\\?PubkeyAuthentication.*/PubkeyAuthentication yes/\" /etc/ssh/sshd_config" , - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q 'PubkeyAuthentication no' /etc/ssh/sshd_config" - }, - { - "id": "SSH07", - "description": "Disable OTP authentication", - "command": [ - "clear", - "! check_if_installed libpam-google-authenticator && ! check_if_installed qrencode || debconf-apt-progress -- apt-get -y purge libpam-google-authenticator qrencode", - "sed -i \"s/^#\\?ChallengeResponseAuthentication.*/ChallengeResponseAuthentication no/\" /etc/ssh/sshd_config || sed -i \"0,/KbdInteractiveAuthentication/s//ChallengeResponseAuthentication yes/\" /etc/ssh/sshd_config" , - "sed -i '/^auth required pam_google_authenticator.so nullok/ d' /etc/pam.d/sshd", - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q 'ChallengeResponseAuthentication yes' /etc/ssh/sshd_config" - }, - { - "id": "SSH08", - "description": "Enable OTP authentication", - "command": [ - "check_if_installed libpam-google-authenticator || debconf-apt-progress -- apt-get -y install libpam-google-authenticator", - "check_if_installed qrencode || debconf-apt-progress -- apt-get -y install qrencode", - "sed -i \"s/^#\\?ChallengeResponseAuthentication.*/ChallengeResponseAuthentication yes/\" /etc/ssh/sshd_config || sed -i $'/KbdInteractiveAuthentication/{iChallengeResponseAuthentication yes\\n:a;n;ba}' /etc/ssh/sshd_config" , - "sed -n -i '/password updating/{p;:a;N;/@include common-password/!ba;s/.*\\n/auth required pam_google_authenticator.so nullok\\nauth required pam_permit.so\\n/};p' /etc/pam.d/sshd", - "[ ! -f /root/.google_authenticator ] && qr_code generate", - "systemctl restart sshd.service" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "! check_if_installed libpam-google-authenticator || ! check_if_installed qrencode || grep -q '^ChallengeResponseAuthentication no' /etc/ssh/sshd_config || ! grep -q 'ChallengeResponseAuthentication' /etc/ssh/sshd_config" - }, - { - "id": "SSH09", - "description": "Generate new OTP authentication QR code", - "command": [ - "qr_code generate" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "", - "condition": "grep -q '^ChallengeResponseAuthentication yes' /etc/ssh/sshd_config" - }, - { - "id": "SSH10", - "description": "Show OTP authentication QR code", - "command": [ - "qr_code" - ], - "status": "Active", - "doc_link": "", - "src_reference": "", - "author": "Igor Pecovnik", - "condition": "grep -q '^ChallengeResponseAuthentication yes' /etc/ssh/sshd_config && [ -f /root/.google_authenticator ]" - } - ] } - ] + ] }, { "id": "Localisation", From 27b5e6dbee7b7e0aa58872085ac295e7b59d3bd3 Mon Sep 17 00:00:00 2001 From: Joey Turner Date: Tue, 3 Sep 2024 19:45:06 -0500 Subject: [PATCH 3/5] Update config.ng.jobs.json fixed merge conflict --- lib/armbian-configng/config.ng.jobs.json | 35 ++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/lib/armbian-configng/config.ng.jobs.json b/lib/armbian-configng/config.ng.jobs.json index c651f9f21..c9dc87d64 100644 --- a/lib/armbian-configng/config.ng.jobs.json +++ b/lib/armbian-configng/config.ng.jobs.json @@ -214,6 +214,41 @@ "condition": "grep -q '^ChallengeResponseAuthentication yes' /etc/ssh/sshd_config && [ -f /root/.google_authenticator ]" } ] + }, + + { + "id": "S30", + "description": "Change shell system wide to BASH", + "command": [ + "export BASHLOCATION=$(grep /bash$ /etc/shells | tail -1)", + "sed -i \"s|^SHELL=.*|SHELL=${BASHLOCATION}|\" /etc/default/useradd", + "sed -i \"s|^DSHELL=.*|DSHELL=${BASHLOCATION}|\" /etc/adduser.conf", + "debconf-apt-progress -- apt-get -y purge armbian-zsh", + "update_skel", + "awk -F'[/:]' '{if ($3 >= 1000 && $3 != 65534 || $3 == 0) print $1}' /etc/passwd | xargs -L1 chsh -s $(grep /bash$ /etc/shells | tail -1)" + ], + "status": "Pending Review", + "doc_link": "", + "src_reference": "", + "author": "https://github.com/igorpecovnik", + "condition": "[[ $(cat /etc/passwd | grep \"^root:\" | rev | cut -d\":\" -f1 | cut -d\"/\" -f1| rev) == \"zsh\" ]]" + }, + { + "id": "S31", + "description": "Change shell system wide to ZSH", + "command": [ + "export ZSHLOCATION=$(grep /zsh$ /etc/shells | tail -1)", + "sed -i \"s|^SHELL=.*|SHELL=${ZSHLOCATION}|\" /etc/default/useradd", + "sed -i \"s|^DSHELL=.*|DSHELL=${ZSHLOCATION}|\" /etc/adduser.conf", + "debconf-apt-progress -- apt-get -y install armbian-zsh", + "update_skel", + "awk -F'[/:]' '{if ($3 >= 1000 && $3 != 65534 || $3 == 0) print $1}' /etc/passwd | xargs -L1 chsh -s $(grep /zsh$ /etc/shells | tail -1)" + ], + "status": "Pending Review", + "doc_link": "", + "src_reference": "", + "author": "https://github.com/igorpecovnik", + "condition": "[[ $(cat /etc/passwd | grep \"^root:\" | rev | cut -d\":\" -f1 | cut -d\"/\" -f1| rev) == \"bash\" ]]" } ] From ab998494b07acf226751b687c2bbbc6766f97591 Mon Sep 17 00:00:00 2001 From: Joey Turner Date: Tue, 3 Sep 2024 19:49:17 -0500 Subject: [PATCH 4/5] Update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 1b5a167e2..1f7d578a0 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,8 @@ sudo armbian-config - **S05** - Remove Linux headers - **S06** - Install to internal storage - **S07** - Manage SSH login options + - **S30** - Change shell system wide to BASH + - **S31** - Change shell system wide to ZSH - ## **Network** - **N00** - Install Bluetooth support From 2892e8185cf0c6fa446301a9c18a4eb9afdb2a46 Mon Sep 17 00:00:00 2001 From: Tearran Date: Tue, 3 Sep 2024 21:24:14 -0400 Subject: [PATCH 5/5] fixed doc --- README.md | 14 ++++++++++++-- lib/armbian-configng/config.ng.docs.sh | 5 +++-- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 0be079e19..82f2c000d 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Armbian Configuration Utility -Updated: Sun Sep 1 03:03:48 PM EDT 2024 +Updated: Tue Sep 3 09:22:06 PM EDT 2024 Utility for configuring your board, adjusting services, and installing applications. It comes with Armbian by default. @@ -21,7 +21,6 @@ sudo armbian-config - **S31** - Change shell system wide to ZSH - - ## **Network** - **N00** - Install Bluetooth support - **N01** - Remove Bluetooth support @@ -94,6 +93,7 @@ Usage: armbian-configng [option] [arguments] --cli S04 - Install Linux headers --cli S05 - Remove Linux headers --cli S06 - Install to internal storage + --cli S07 - Manage SSH login options --cli S30 - Change shell system wide to BASH --cli S31 - Change shell system wide to ZSH --cli N00 - Install Bluetooth support @@ -212,6 +212,16 @@ Jobs: armbian-install ~~~ +### S07 + +Manage SSH login options + +Jobs: + +~~~ +No commands available +~~~ + ### S30 Change shell system wide to BASH diff --git a/lib/armbian-configng/config.ng.docs.sh b/lib/armbian-configng/config.ng.docs.sh index 5237762ad..c07b2ed37 100644 --- a/lib/armbian-configng/config.ng.docs.sh +++ b/lib/armbian-configng/config.ng.docs.sh @@ -458,11 +458,12 @@ jq -r ' .menu[] | .sub[] | "### " + .id + "\n\n" + - .description + "\n\nJobs:\n\n~~~\n" + - (.command | join("\n")) + + (.description // "No description available") + "\n\nJobs:\n\n~~~\n" + + ((.command // ["No commands available"]) | join("\n")) + "\n~~~\n" ' $json_file } + module_options+=( ["see_cli_list,author"]="Joey Turner" ["see_cli_list,ref_link"]=""