Updated timezone script since timedatectl set-ntp seems to be working now.

This commit is contained in:
Storm Dragon 2024-03-12 16:45:56 -04:00
parent 8c0e76b535
commit 157c5cc9e3

View File

@ -25,11 +25,7 @@ sudo "${sudoFlags[@]}" timedatectl set-timezone ${region}/${city}
if [[ -f /etc/localtime ]]; then if [[ -f /etc/localtime ]]; then
sudo "${sudoFlags[@]}" rm /etc/localtime sudo "${sudoFlags[@]}" rm /etc/localtime
fi fi
sudo "${sudoFlags[@]}" ln -s /usr/share/zoneinfo/${region}/${city} /etc/localtime sudo "${sudoFlags[@]}" ln -sf /usr/share/zoneinfo/${region}/${city} /etc/localtime
# Make sure we are syncing with the internet # Make sure we are syncing with the internet
echo "Setting up ntpd" sudo "${sudoFlags[@]}" timedatectl set-ntp true
sudo "${sudoFlags[@]}" timedatectl set-ntp false
sudo "${sudoFlags[@]}" systemctl stop ntpd
sudo "${sudoFlags[@]}" ntpd -Ggq &> /dev/null
sudo "${sudoFlags[@]}" systemctl enable ntpd --now