From fc674a355b533c448290ffb4ace7e9160be63715 Mon Sep 17 00:00:00 2001 From: deadcxap <36386824+deadcxap@users.noreply.github.com> Date: Sun, 24 Aug 2025 10:15:16 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9A=D0=BE=D1=80=D1=80=D0=B5=D0=BA=D1=82?= =?UTF-8?q?=D0=BD=D0=BE=D0=B5=20=D0=B4=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D0=B8=D0=B5=20Include=20=D0=B2=20sshd=5Fconfig?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- setup.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.sh b/setup.sh index dd052e8..e1b4f36 100644 --- a/setup.sh +++ b/setup.sh @@ -126,8 +126,8 @@ configure_ssh() { printf \"%s\n\" \"$SSH_KEY\" > \"/home/$USERNAME/.ssh/authorized_keys\" chmod 600 \"/home/$USERNAME/.ssh/authorized_keys\" chown -R \"$USERNAME\":\"$USERNAME\" \"/home/$USERNAME/.ssh\" - if ! grep -qE '^[[:space:]]*Include[[:space:]]+/etc/ssh/sshd_config.d/\\*.conf' /etc/ssh/sshd_config; then - echo 'Include /etc/ssh/sshd_config.d/*.conf' >> /etc/ssh/sshd_config + if ! grep -qE '^[[:space:]]*Include[[:space:]]+/etc/ssh/sshd_config.d/\*.conf' /etc/ssh/sshd_config; then + sed -i '1iInclude /etc/ssh/sshd_config.d/*.conf' /etc/ssh/sshd_config fi install -d -m 755 /etc/ssh/sshd_config.d dir=/etc/ssh/sshd_config.d