This is an automated email from the ASF dual-hosted git repository.

msciabarra pushed a commit to branch main
in repository 
https://gitbox.apache.org/repos/asf/openserverless-devcontainer.git


The following commit(s) were added to refs/heads/main by this push:
     new a7be237  using supervisord
a7be237 is described below

commit a7be237783f0fffb55d651942eca825130ec6484
Author: Michele Sciabarra <[email protected]>
AuthorDate: Sun Nov 23 16:09:20 2025 +0000

    using supervisord
---
 start.sh        | 7 +++++--
 supervisord.ini | 2 +-
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/start.sh b/start.sh
index e777496..0743cc4 100755
--- a/start.sh
+++ b/start.sh
@@ -19,8 +19,11 @@ fi
 if test -n "$SSHKEY"
 then
     mkdir -p $HOME/.ssh
-    echo "$SSHKEY" >>$HOME/.ssh/authorized_keys
-    chmod 600 ~/.ssh/authorized_keys
+    if ! grep "$SSHKEY" $HOME/.ssh/authorized_keys
+    then echo "$SSHKEY" >>$HOME/.ssh/authorized_keys
+    fi
+    chmod 600 $HOME/.ssh/authorized_keys
+    chmod 700 $HOME/.ssh
 fi
 
 # fix permissions
diff --git a/supervisord.ini b/supervisord.ini
index e7c530d..93ea277 100644
--- a/supervisord.ini
+++ b/supervisord.ini
@@ -6,7 +6,7 @@ pidfile=/tmp/supervisord.pid
 user=root
 
 [program:sshd]
-command=/usr/sbin/sshd -p 2222 -D
+command=/usr/sbin/sshd -p 2222 -D -e
 directory=/
 user=root
 autostart=true

Reply via email to