netbox-community / netbox

The premier source of truth powering network automation. Open source under Apache 2. Try NetBox Cloud free: https://netboxlabs.com/free-netbox-cloud/
http://netboxlabs.com/oss/netbox/
Apache License 2.0
16.04k stars 2.57k forks source link

Site Timezone Selection #1283

Closed rsaturns closed 6 years ago

rsaturns commented 7 years ago

Issue type: Feature Request

When adding a site it would be nice to have a Timezone field that could be selected. This would then document the local Timezone for the site. Additionally if selected below it could display the sites current local time as calculated from the servers off-set.

For example, the server is set to PST and the time is 0700 and the date is June-16-2017. Site timezone is selected as EST.

The selection field shows: US/Eastern Below the selection field is actual time: 10:00 US/Eastern June-16-2017

jeremystretch commented 7 years ago

I like it, but we need to figure out how to cultivate a list of timezones for a user to choose from. Something like django-timezone-field should work, although it would introduce a new dependency, and I'm not sure how we'd maintain timezone choices over time.

rsaturns commented 7 years ago

What about if on the Django admin portal you exposed all the Timezones as tick boxes. Then as an admin, you select the ones you want to apply to you. In our case, as a global company we really only operate in about 14 timezones world wide. So I'd "tick" those 14 which would then be presented to me in the drop-down list on the add site front end?

rkutsel commented 7 years ago

I'm might be totally off base here but what's wrong with setting it to UTC which should be a gold standard for local times worldwide. I don't see any practical use case here other than a convenience.

jeremystretch commented 7 years ago

I think the proposal is simply to track the local time for each site, so that it can be referenced in maintenance notices and whatnot.

rsaturns commented 7 years ago

That is exactly correct. Nothing is more fun then to have an operations team do a page out to on-call only to find out it's for a site that is past business hours with no contacts.

rkutsel commented 7 years ago

Makes sense. This feature will definitely come in handy.

vsvetlov commented 6 years ago

It would be nice to add "maintenance window" field for a site model. For example 11 PM - 6AM.

Can a current time field be highlighted with different colours if it is in or out of site's MW?

jeremystretch commented 6 years ago

Implemented in b20258c

lmgonzalezl commented 5 years ago

Hi.

First, give thanks for the contribution you have made with Netbox.

We are implementing it in the company and we would like to change the TIME_ZONE in the configuration.py file to adjust it to our time use. We are in the Canary Islands - Spain and our time use is UTC +01: 00. I have placed TIME_ZONe = 'UTP +01: 00' but it does not work. Can you tell me what is the correct way to assign this parameter?

Greetings and thank you.

lmgonzalezl commented 5 years ago

Resolved.

TIME_ZONE = "Atlantic/Canary"

Thank you.