From f69e8dc8340e9a60ecc586dfba0ce1ad26429996 Mon Sep 17 00:00:00 2001 From: thek4n Date: Fri, 18 Oct 2024 10:37:55 +0300 Subject: [PATCH] add motd files --- etc/update-motd.d/10-figlet | 4 ++++ etc/update-motd.d/20-service-status.example | 9 +++++++++ 2 files changed, 13 insertions(+) create mode 100755 etc/update-motd.d/10-figlet create mode 100755 etc/update-motd.d/20-service-status.example diff --git a/etc/update-motd.d/10-figlet b/etc/update-motd.d/10-figlet new file mode 100755 index 0000000..f29a95b --- /dev/null +++ b/etc/update-motd.d/10-figlet @@ -0,0 +1,4 @@ +#!/bin/bash +echo +figlet -ct -f banner "welcome mr.kan" +echo \ No newline at end of file diff --git a/etc/update-motd.d/20-service-status.example b/etc/update-motd.d/20-service-status.example new file mode 100755 index 0000000..971155c --- /dev/null +++ b/etc/update-motd.d/20-service-status.example @@ -0,0 +1,9 @@ +#!/bin/bash + +echo wg0 status: $(systemctl is-active wg-quick@wg0.service) + +if ! systemctl is-active wg-quick@wg0.service &>/dev/null; then + echo 'Executing this command may fix wireguard: "sudo apt update && sudo apt install linux-headers-$(uname -r) && sudo reboot"' +fi + +echo \ No newline at end of file