Update 2 files

- /home/.chezmoidata.yaml
- /home/private_dot_ssh/system/run_onchange_after_sshd.tmpl
This commit is contained in:
Brian Zalewski 2023-02-01 21:30:51 +00:00
parent c9b1823969
commit 8deb2cb47d
2 changed files with 8 additions and 0 deletions

View file

@ -812,6 +812,7 @@ softwareGroups:
- *Essentials
- endlessh
- fail2ban
- openssh-server
_Basic-Desktop: &_Basic-Desktop
- *_Basic
- *Essentials-Desktop

View file

@ -16,6 +16,13 @@ if [[ ! "$(grep Microsoft /proc/version)" ]]; then
logg info 'Copying ~/.ssh/system/sshd_config to /etc/ssh/sshd_config'
sudo cp -f "$HOME/.ssh/system/sshd_config" /etc/ssh/sshd_config
if command -v semanage > /dev/null; then
logg info 'Apply SELinux configuration addressing custom SSH port'
sudo semanage port -a -t ssh_port_t -p tcp {{ .host.ssh.port }}
logg info 'Allow NIS SSHD'
sudo setsebool -P nis_enabled 1
fi
### Restart SSH server
if [ -d /Applications ] && [ -d /System ]; then
# macOS