From cb040df48b0c5121e229ca331263a7f4ac53ee42 Mon Sep 17 00:00:00 2001 From: Kevin Baensch Date: Fri, 6 Jan 2023 09:36:27 +0100 Subject: [PATCH] Always restart sshd after setup. --- setup.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/setup.sh b/setup.sh index cdb98f6..1e625d1 100755 --- a/setup.sh +++ b/setup.sh @@ -103,9 +103,6 @@ setup_sqlproxy() { then printf 'command="/sqlproxy_cli.sh" %s\n' "${PUB_KEY}" >> "${PROJECT_PATH}/etc/ssh/.ssh/authorized_keys" fi - - printf 'Restarting sql proxy (if running) to fix permissions.\n' - docker compose --project-directory "${PROJECT_PATH}" -f "${PROJECT_PATH}/docker-compose.yml" restart sshd else printf 'Not generating client ssh key.\nPlease put your desired public keys into %s\nAlso add %s in front of your key\n' "${PROJECT_PATH}/etc/ssh/.ssh/authorized_keys" "'command=\"/sqlproxy_cli.sh\" '" fi @@ -122,3 +119,6 @@ if check 'Configure sql proxy? [Y/n] ' then setup_sqlproxy fi + +printf 'Restarting sql proxy (if running) to fix permissions.\n' +docker compose --project-directory "${PROJECT_PATH}" -f "${PROJECT_PATH}/docker-compose.yml" restart sshd