greetd/src/server.rs on line 27 calls
However TerminalMode::Terminal constructed with hardcoded
switch: true or
When greetd is started with agreety for multiple terminals, each greetd results in calling
term.vt_setactivate which causes:
I would suggest to add
switch option in
ConfigTerminal, and pass it to
TerminalMode::Terminal, so that primary terminal could be configured to call
term.vt_setactivate and others not.
Another (also arguably better) way could be delaying greetd worker until designated terminal is active.
let term_mode = get_tty(&config)?;
it could be possible to wait for
term_mode.vtto become active before proceeding using any of:
- ioctl: VT_WAITACTIVE
- inotify: /sys/devices/virtual/tty/tty0/active
- or similar
Then if user never switches to specific tty, greetd won't start worker and greeter for it.