mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-04-08 02:04:47 +02:00
Replaced HOST and HOSTNAME variable through hostname command to make it more distribution indepentend
This commit is contained in:
parent
c31a8fb329
commit
d5ba306081
@ -1,2 +1,2 @@
|
||||
#!/bin/bash
|
||||
/usr/bin/curl -s -X POST https://api.telegram.org/bot{{ telegram_bot_token }}/sendMessage -d chat_id={{ telegram_chat_id }} -d text="service $1 on $HOST failed"
|
||||
/usr/bin/curl -s -X POST https://api.telegram.org/bot{{ telegram_bot_token }}/sendMessage -d chat_id={{ telegram_chat_id }} -d text="service $1 on $(hostname) failed"
|
||||
|
@ -20,7 +20,7 @@ clear
|
||||
PRIMARY_IP=$(ip route get 8.8.8.8 2>/dev/null | awk '{print $7}' | head -n1)
|
||||
|
||||
# Print welcome message
|
||||
echo -e "${HEADER_COLOR}Welcome, $USER on ${HOSTNAME_COLOR}$HOSTNAME!${RESET_COLOR}"
|
||||
echo -e "${HEADER_COLOR}Welcome, $USER on ${HOSTNAME_COLOR}$(hostname)!${RESET_COLOR}"
|
||||
echo -e "Primary IP Address: ${PRIMARY_IP}"
|
||||
echo -e "${HEADER_COLOR}Today is $(date +"%A, %d.%m.%Y %T")${RESET_COLOR}"
|
||||
echo -e "\033[94mPowered by: CyMaIS - Cyber Master Infrastructure Solutions!"
|
||||
|
Loading…
x
Reference in New Issue
Block a user