You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to run WSL as a system service for some servers (such as sshd, crond, tftpd) in the background, before Windows user log in, and it continues to run after I close all mintty terminals(connections).
Is it possible?
Thanks.
The text was updated successfully, but these errors were encountered:
Are you sure wslbridge is relevant here? wslbridge is a way to bridge from a Cygwin (or MSYS2) pty to a WSL pty.
Both WSL and Cygwin have servers like sshd. If you were to run Cygwin's SSH server, then you could use wslbridge after logging in to start a WSL shell.
My impression is that you're interested in running WSL servers rather than Cygwin servers, though. There's an issue open here (microsoft/WSL#612) about running WSL sshd as a Windows service, but after skimming it, I couldn't tell if anyone figured out a solution. It seems that each Windows account has an independent WSL installation, so running WSL sshd as "SYSTEM"(?) won't work, because it won't see your real home directory? Maybe you could run the WSL sshd Windows service with your ordinary Windows account. I'm not familiar with WSL's security model or how it handles multiple accounts.
Well I thought it would be nice for wslbridge to provide a "service mode" that it does not connect to mintty while still can run some bash processes in the background, thus it acts like "Windows service".
Per your question regarding Windows account, you can always specify to run service using a normal account instead of SYSTEM.
I used to run a user console executable as service with an older version of Windows. But Windows 10's bash.exe seems to have console issue that my service could not be fully stopped and stays STOPPING state.
Hello,
I want to run WSL as a system service for some servers (such as sshd, crond, tftpd) in the background, before Windows user log in, and it continues to run after I close all mintty terminals(connections).
Is it possible?
Thanks.
The text was updated successfully, but these errors were encountered: