feat(startwm): surface session logs when SELKIES_DEBUG is enabled (openbox + labwc) - #180
Conversation
|
Three things here:
On the fence here, while I see the value of it users can always run the applications from the command line inside their containers to see what is happening and get output there. This would only open up showing labwc/openbox logs which are pretty uninteresting. I do not have a great solution for this that would not see a bunch of code duplication or use use stdout/stderr rebinding to 3 and 4. I'll think about a potential solution, but anything downstream can run any startwm.sh they want that is how stuff like webtop works and this is documented. |
|
Thanks for the detailed look, all three addressed:
No fd rebinding and no duplicated code, just the existing redirect made conditional in the two session scripts. Happy to drop it if you'd still rather keep this downstream, but making |
|
Rebased onto current master (the branch was based on an older master, so the previous diff looked noisy) and reworked to keep it minimal: a single |
b9fc2c2 to
28ec666
Compare
|
Did you test this? I think the duplication of logic is unavoidable honestly, abc cannot write to stdout |
|
Let's put a pin in this as I said I am on the fence, downstream containers can modify their own startwm script. As support stands right now I prefer having people run the apps in the container from console to get logs for specific apps. |
|
Thanks for weighing it, that's fair. You're right that abc can't write to the container stdout, so surfacing it there needs more than a conditional redirect, and I take the point about keeping the default support flow console-based. I'll keep this downstream in my own images instead. Appreciate the look. |
|
Just a heads up given the number of PRs and how building out all these bases works and the time that it takes to build them the other PRs you have submitted will come in one patch, if you want to be in the commit history looks like this If you don't care I am directly committing these tomorrow after full testing. |
|
Sounds good, no objection at all, please go ahead and commit them, and yes I'd be glad to be in the commit history. Thanks for folding them in. One thing that got dropped from the empty-PASSWORD change (#179): the batch keeps the guard on the That also stops treating |
Currently both session scripts send their output to /dev/null, so
SELKIES_DEBUG=truecannot tell you why an autostart entry or the desktop itself failed to come up.This makes the existing
SELKIES_DEBUGflag also cover session startup: when it is enabled, the openbox session (startwm.sh) and the labwc/wayland session (startwm_wayland.sh) route their output (autostart, app launchers, ready banners) to the container log. Default behaviour is unchanged and quiet.No new env var, no fd rebinding, no duplicated code, just the existing redirect made conditional in the two session scripts.