https://netmaker.org logo
Can the apt package `postinst` (or equivalent) hav...
# client
c
Can the apt package
postinst
(or equivalent) have a
systemctl daemon-reload
added before you try restarting the client? Otherwise I have to run that and restart the client every time you update the service file
b
this is the postinst script any suggestions for improvement are welcome
Copy code
#!/bin/sh
set -e
systemctl preset netclient

if [ "$1" = upgrade ]; then
    systemctl daemon-reload
    systemctl enable netclient
    systemctl restart netclient
fi
c
I don't think it's being hit, systemd complains each time that the daemon needs reloading. I'm no expert on systemd and haven't used
preset
. I would be tempted to change it about like this: systemctl daemon-reload systemctl preset netclient systemctl enable netclient systemctl restart netclient
Do you care if it's upgrading? Edit: meaning, do you need to check?
5 Views