change time zone in heruko app to +3GMT
https://chatgpt.com/share/67111a66-6b88-8013-af6f-170d136f7cd0
To change the time zone of a Heroku app to GMT+3, you can configure the time zone by setting the environment variable TZ in the Heroku settings.
Here's how you can do it:
Steps:
Login to Heroku:
- Open your Heroku Dashboard and log in.
Go to Your App:
- Select the app for which you want to change the time zone.
Configure Environment Variables:
- Click on the "Settings" tab of your Heroku app.
- Scroll down to the section "Config Vars".
- Click on the "Reveal Config Vars" button.
Add Time Zone:
- In the "Key" field, type
TZ. - In the "Value" field, type
Etc/GMT-3(note that GMT+3 is represented asGMT-3in time zone settings). - Click "Add".
- In the "Key" field, type
Why use Etc/GMT-3?
In the TZ configuration, the positive offsets from UTC are written with a minus sign (GMT-3), while negative offsets are written with a plus sign. This can be a little counterintuitive.
Once added, your application will use GMT+3 for any time-related operations.
Example:
Now your Heroku app will run on GMT+3!
تعليقات
إرسال تعليق