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 7bcc749 commit 6d02689Copy full SHA for 6d02689
components/supervisor/pkg/supervisor/ssh.go
@@ -104,6 +104,7 @@ func (s *sshServer) handleConn(ctx context.Context, conn net.Conn) {
104
args = append(args,
105
"-ieD", "-f/dev/null",
106
"-oProtocol 2",
107
+ "-oAllowUsers gitpod",
108
"-oPasswordAuthentication no",
109
"-oChallengeResponseAuthentication no",
110
"-oPermitRootLogin yes",
@@ -158,6 +159,7 @@ func (s *sshServer) handleConn(ctx context.Context, conn net.Conn) {
158
159
160
log.WithField("args", args).Debug("sshd flags")
161
cmd := exec.CommandContext(ctx, openssh, args...)
162
+ cmd = runAsGitpodUser(cmd)
163
cmd.Env = s.envvars
164
cmd.ExtraFiles = []*os.File{socketFD}
165
cmd.Stderr = os.Stderr
0 commit comments