You are viewing a single thread.
View all comments View context
8 points

It’s a node process invoked by a run.sh, which gets executed via a .desktop file in the ~/.config/autostart directory.

I went with a systemd unit now and it works.

permalink
report
parent
reply
1 point

Your DE may be the one not relaying the sigterm, or it may be losing the PID because of the double launching.

Does the LSB have something to call on termination? Or you may want to call an executable there instead of a script.

permalink
report
parent
reply
8 points
*

I can’t remember off the top of my head, but your shell script might not be relaying the SIGTERM. Make sure you start your node process with the “exec” statement. This will replace the script’s process with node instead of having node be a subprocess of your script.

permalink
report
parent
reply
3 points

When I run the script myself and kill it, it gets the signal and acts correctly. Only when I poweroff the system, this doesn’t work.

I also tried prepending exec, but no dice.

permalink
report
parent
reply
3 points

“SyStEmD iS bLoAt…”

permalink
report
parent
reply

Programmer Humor

!programmer_humor@programming.dev

Create post

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics

Community stats

  • 3.8K

    Monthly active users

  • 1.1K

    Posts

  • 39K

    Comments