Unable to set TimeZone for Pod in RHOCP4

Solution Verified - Updated -

Issue

  • Pod is not reflecting the correct time zone even after setting the correct environment variable:
$ oc rsh tomcat-pod-xxx
/usr/local/tomcat $ env | grep TZ
TZ=Asia/Kolkata
/usr/local/tomcat $ date
Tue Apr 16 11:50:33 UTC 2024

Environment

  • Red Hat OpenShift Container Platform (RHOCP) 4

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content