I have a KC instance running in a docker container. Since yesterday I have a strange behavior that I don’t understand. Every time I request a token the
issued at date is
Wednesday 19 February 2020, I just try it today (Wednesday 03 March 2020) and I have the same result.
When I send the token to my Spring Boot/Spring Security 5.2 app it throws an error because the token is expired.
This is the first time I have this issue.
Does someone know why I have this problem and how can I solve it?
Thanks a lot.
What’s the time in your container?
I just checked and I was suprised to see that the container date is
Wed Feb 19 07:30:16 UTC 2020 and the host time is
Wed Mar 4 18:38:52 2020. What the hell happened? Why the KC container is stuck in the past?
For curiosity I created a new container from the same KC image and the container date is the same
Wed Feb 19 07:43:06 UTC 2020.
I finally found the reason of this issue. The container clock freezes when the host is in hibernate mode. See here https://github.com/docker/for-win/issues/4526#issuecomment-594719605