openssh: support SSH_ENABLED_DEFAULT option

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
This commit is contained in:
Christian Hewitt 2025-04-20 04:21:22 +00:00
parent f0a7445fb4
commit ef377a261e
No known key found for this signature in database
3 changed files with 9 additions and 0 deletions

View File

@ -94,6 +94,9 @@
# local console login prompt (yes / no)
LOCAL_LOGIN="yes"
# Enable SSH on boot (yes / no)
SSH_ENABLED_DEFAULT="yes"
### KODI SETTINGS ###
# Mediacenter to use (kodi / no)
MEDIACENTER="no"

View File

@ -94,6 +94,9 @@
# local console login prompt (yes / no)
LOCAL_LOGIN="no"
# Enable SSH on boot (yes / no)
SSH_ENABLED_DEFAULT="no"
### KODI SETTINGS ###
# Mediacenter to use (kodi / no)
MEDIACENTER="kodi"

View File

@ -55,5 +55,8 @@ post_makeinstall_target() {
}
post_install() {
if [ "${SSH_ENABLED_DEFAULT}" = "yes" ]; then
sed -e "\|^Condition.*|d" -i ${INSTALL}/usr/lib/systemd/system/sshd.service
fi
enable_service sshd.service
}