mirror of
https://github.com/nix-community/nix-on-droid.git
synced 2025-11-08 19:46:07 +01:00
fixup ssh: add autostart option
This commit is contained in:
parent
f861f458e7
commit
b416b58595
1 changed files with 11 additions and 0 deletions
|
|
@ -45,6 +45,16 @@ in {
|
|||
type = types.bool;
|
||||
default = false;
|
||||
};
|
||||
autostart = lib.mkOption {
|
||||
description = ''
|
||||
Whether to automatically start the OpenSSH daemon.
|
||||
|
||||
If false, the server has to be manually started using
|
||||
`supervisorctl`.
|
||||
'';
|
||||
type = types.bool;
|
||||
default = true;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = ''
|
||||
The package to use for OpenSSH.
|
||||
|
|
@ -100,6 +110,7 @@ in {
|
|||
};
|
||||
|
||||
supervisord.programs.sshd = {
|
||||
inherit (cfg) autostart;
|
||||
path = [ cfg.package ];
|
||||
autoRestart = true;
|
||||
script = ''
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue