( )⚙ D2464 debugcommands: add debugserve command

This is an archive of the discontinued Mercurial Phabricator instance.

debugcommands: add debugserve command
ClosedPublic

Authored by indygreg on Feb 26 2018, 4:16 PM.

Details

Summary

hg serve --stdio requires the exact command argument form
hg -R <path> serve --stdio for security reasons. An upcoming
commit will need to start an SSH protocol server process with
custom settings.

This commit creates a hg debugserve command for starting servers
with custom options. There are no security restrictions and we can
add options here that aren't appropriate for built-in commands.

We currently only support starting an SSH protocol server using
the process's stdio file descriptors. The server supports logging
its I/O activity to a file descriptor number passed as a command
argument.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

indygreg created this revision.Feb 26 2018, 4:16 PM
indygreg updated this revision to Diff 6179.Feb 27 2018, 6:47 PM
indygreg updated this revision to Diff 6249.Mar 1 2018, 11:30 AM
durin42 accepted this revision.Mar 1 2018, 4:13 PM
This revision is now accepted and ready to land.Mar 1 2018, 4:13 PM
This revision was automatically updated to reflect the committed changes.