WSL Wrong Time: How to Fix incorrect Time in WSL

While working with AWS SAM I ran into an error caused by the local system time of WSL being wrong. In the above image notice that the date command outputs the hour being 4. A call to worldtimeapi.org for my timezone shows the time being 12. Something is wrong. World time API call formatted with JQ: curl -s "http://worldtimeapi.org/api/ip" | jq '.["datetime"]' I attempted to re-configure WSL Ubuntu’s time with sudo dpkg-reconfigure tzdata...

July 13, 2020 · 2 min · chart