#!/bin/bash
# Set NTP parameters
echo -e "[Time]
NTP=ntp.lgs.lv
FallbackNTP=0.lv.pool.ntp.org 1.lv.pool.ntp.org 2.lv.pool.ntp.org 3.lv.pool.ntp.org
RootDistanceMaxSec=5
PollIntervalMinSec=32
PollIntervalMaxSec=2048
ConnectionRetrySec=30
SaveIntervalSec=60" | sudo tee /etc/systemd/timesyncd.conf > /dev/null
# Set 24 hours time format
sudo locale-gen en_GB.UTF-8
sudo update-locale LANG=en_GB.UTF-8 LC_TIME=en_GB.UTF-8
sudo timedatectl set-timezone Etc/UTC
sudo systemctl restart systemd-timesyncd

