# AWX API - timezone

**URL:** <https://forum.ansible.com/t/awx-api-timezone/36402>\
**Category:** AWX Project\
**Tags:** awx, kubernetes\
**Created:** [March 5, 2022, 12:53pm UTC](https://forum.ansible.com/t/awx-api-timezone/36402 "2022-03-05T12:53:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Martin\_Gabriel](https://avatars.discourse-cdn.com/v4/letter/m/a87d85/32.png) [@Martin\_Gabriel](https://forum.ansible.com/u/Martin_Gabriel)\
**Post date:** [March 5, 2022, 12:53pm UTC](https://forum.ansible.com/t/awx-api-timezone/36402/1 "2022-03-05T12:53:04Z")

</div>

Hello,

im already desperate about changing my AWX 20.0.0 (running in kubernetes) timezone.

All templates are static Europe/Prague.  
For some maintenance jobs im using AWX api to obtain some relevant data ( like job start/finish/status etc.)  
Im strugling with API timezone which is set UTC and therefore all my outputs are one hour moved.

In my #/api/v2/config i see:

“time\_zone”: “UTC”

I already tryed to force`env` to pod like

env:

- name: TIME\_ZONE

value: Europe/Prague

or

tryed to add volume like:

```auto
- mountPath: /etc/timezone
name: awx-configmap-timezone
readOnly: true
subPath: timezone
- mountPath: /etc/localtime
name: awx-configmap-timezone
readOnly: true
subPath: timezone

```

with config map:

```auto
timezone: |
Europe/Prague

```

but AWX-web ignores any of these settings and `date` always return UTC time :

```auto
bash-5.1$ date
Sat Mar 5 12:49:21 PM UTC 2022

```

Is here anyone who can help if its somehow possible to edit /api/v2/config or somehow force pod to use different timezone…

Thank you in advance  
Martin

---

<div class="post-metadata">

**Author:** ![Martin\_Gabriel](https://avatars.discourse-cdn.com/v4/letter/m/a87d85/32.png) [@Martin\_Gabriel](https://forum.ansible.com/u/Martin_Gabriel)\
**Post date:** [March 5, 2022, 1:14pm UTC](https://forum.ansible.com/t/awx-api-timezone/36402/2 "2022-03-05T13:14:24Z")

</div>

UPDATE:  
I managed to force all pod containers to use CET… but AWX-API still uses UTC

Dne sobota 5. března 2022 v 13:53:04 UTC+1 uživatel Martin Gabriel napsal:

---

<div class="post-metadata">

**Author:** ![Martin\_Gabriel](https://avatars.discourse-cdn.com/v4/letter/m/a87d85/32.png) [@Martin\_Gabriel](https://forum.ansible.com/u/Martin_Gabriel)\
**Post date:** [March 7, 2022, 10:00am UTC](https://forum.ansible.com/t/awx-api-timezone/36402/3 "2022-03-07T10:00:04Z")

</div>

for anyone interested,

define config map settings.py by adding:

```auto
USE_TZ = True
TIME_ZONE = 'CET'

```

API is now CET with correct time in my timezone

Dne sobota 5. března 2022 v 14:14:24 UTC+1 uživatel Martin Gabriel napsal:
