diff --git a/install.sh b/install.sh index 03f5cea..8b16432 100755 --- a/install.sh +++ b/install.sh @@ -209,6 +209,7 @@ install_symlink /usr/bin/ptype "$DESTDIR$usrlocal_pre install_symlink /usr/bin/pman "$DESTDIR$usrlocal_prefix/package/bin/pman" install_data misc_etc_files/sysctl.conf "$DESTDIR$sysconfdir/sysctl.conf" install_data misc_etc_files/udev/rules.d/51-mariux.rules "$DESTDIR$sysconfdir/udev/rules.d/51-mariux.rules" +install_data misc_systemd_units/reboot-notify.service "$DESTDIR$systemdunitdir/reboot-notify.service" postinstall exit diff --git a/misc_systemd_units/reboot-notify.service b/misc_systemd_units/reboot-notify.service new file mode 100644 index 0000000..fb5ec0c --- /dev/null +++ b/misc_systemd_units/reboot-notify.service @@ -0,0 +1,11 @@ +[Unit] +Requires=network.target +After=network.target + +[Service] +Type=oneshot +RemainAfterExit=yes +ExecStart=bash -c 'last -20 reboot|mailx -s "[REBOOT] $(hostname)" reboot-notify' + +[Install] +WantedBy=multi-user.target