From 4af3ec7276fc48fbf4696eb7c3c9b83b7d7a4e03 Mon Sep 17 00:00:00 2001 From: Fr4nzD13trich Date: Fri, 10 Oct 2025 17:13:44 +0200 Subject: [PATCH] test script added --- assets/test/test.sh | 6 +++++- dev_env_setup.sh | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/assets/test/test.sh b/assets/test/test.sh index 1744fcb..fa7d691 100755 --- a/assets/test/test.sh +++ b/assets/test/test.sh @@ -1,3 +1,7 @@ #!/bin/bash -sed -i.bak "s/DOMAIN/$HOSTNAME.local/g" nginx.conf \ No newline at end of file +sudo sed -i.backup "s/$HOSTNAME/xXxXx/g" /etc/hosts +sudo sed -i.backup "s/$HOSTNAME/xXxXx/g" /etc/hostname +sudo systemctl reload NetworkManager +#sudo systemctl restart NetworkManager +echo "$hostname" \ No newline at end of file diff --git a/dev_env_setup.sh b/dev_env_setup.sh index a4f5ce6..27434d5 100755 --- a/dev_env_setup.sh +++ b/dev_env_setup.sh @@ -77,6 +77,8 @@ while true; do read -p " Enter new hostname --> " new_hostname sudo sed -i.backup "s/$HOSTNAME/$new_hostname/g" /etc/hosts sudo sed -i.backup "s/$HOSTNAME/$new_hostname/g" /etc/hostname + sleep 3s + sudo systemctl reload NetworkManager echo -e "\n ${GRN}Host name changed to ${LCY}$new_hostname${CRS}" break else