We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 72f69a5 commit 4583639Copy full SHA for 4583639
start.sh
100644
100755
@@ -1,5 +1,12 @@
1
#!/bin/sh
2
3
+_term() {
4
+ echo "Caught SIGTERM signal!"
5
+ kill -TERM "$child" 2>/dev/null
6
+}
7
+
8
+trap _term SIGTERM
9
10
# If there is some public key in keys folder
11
# then it copies its contain in authorized_keys file
12
if [ "$(ls -A /git-server/keys/)" ]; then
@@ -19,5 +26,7 @@ if [ "$(ls -A /git-server/repos/)" ]; then
19
26
find . -type d -exec chmod g+s '{}' +
20
27
fi
21
28
22
-# -D flag avoids executing sshd as a daemon
23
-/usr/sbin/sshd -D
29
+/usr/sbin/sshd
30
31
+child=$!
32
+wait "$child"
0 commit comments