KBEC-00155 - Changing a web server’s time zone

Article ID:360032831072
1 minute readKnowledge base

Summary

CloudBees CD (CloudBees Flow) Web servers can be located in different time zones than end users. When the date and time display on the CloudBees CD (CloudBees Flow) GUI is not in the same time zone as the user, this is both annoying and confusing when looking at job details displays.

Solution

You can change the time zone that the CloudBees CD (CloudBees Flow) Web server uses so it is different from the time zone of the machine on which the Web server is running.

Insert a time zone configuration tag, date_default_timezone_set, explicitly in the file config.php found by default in the CloudBees CD (CloudBees Flow) install directory, apache->htdocs->commander.

date_default_timezone_set("");

After making the change, refresh the GUI display to have the new time zone take effect.

Upgrading CloudBees CD (CloudBees Flow) restores the settings to their default values. You must reapply the time zone change after upgrading.

Example

To set the time zone for Taipei,add:

date_default_timezone_set("Asia/Taipei");

References

For a complete "List of Supported Timezones", see: