You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2020/12/14 10:53:24 UTC

[GitHub] [apisix] ziyou434 opened a new issue #3039: request help: question about time zone

ziyou434 opened a new issue #3039:
URL: https://github.com/apache/apisix/issues/3039


   ### Issue description
   I find there are some code about time zone,but I don't know what they can do or where they can be use.
   ```
   containers:
           - env:
               - name: TZ
                 value: "Asia/Shanghai"
   
   ...
   
   hostPath:
               path: /etc/localtime
               type: File
             name: localtime
   ```
   My company is sensitive to time zone,I want to insure these configs  have no effect .
   
   ### Environment
   
   * apisix version (cmd: `apisix version`): 2.0
   * OS: linux
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] moonming commented on issue #3039: request help: question about time zone

Posted by GitBox <gi...@apache.org>.
moonming commented on issue #3039:
URL: https://github.com/apache/apisix/issues/3039#issuecomment-744416161


   agree, we can not hard code TZ


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] spacewander commented on issue #3039: request help: question about time zone

Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #3039:
URL: https://github.com/apache/apisix/issues/3039#issuecomment-744383657


   ```
   hostPath:
               path: /etc/localtime
               type: File
             name: localtime
   ```
   
   This part of code mounts the host's /etc/localtime to the pod. Quoted from the doc:
   > If the TZ environment variable does not have a value, the operation chooses a time zone by default. In the GNU C Library, the default time zone is like the specification ‘TZ=:/etc/localtime’ (or ‘TZ=:/usr/local/etc/localtime’, depending on how the GNU C Library was configured; see Installation). Other C libraries use their own rule for choosing the default time zone, so there is little we can say about them.
   
   https://www.gnu.org/software/libc/manual/html_node/TZ-Variable.html
   
   ```
   containers:
           - env:
               - name: TZ
                 value: "Asia/Shanghai"
   ```
   I think we should remove this, since it is bad idea to hard code timezone. 
   @membphis @gxthrj What about your guys' opinion?
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] membphis closed issue #3039: request help: question about time zone

Posted by GitBox <gi...@apache.org>.
membphis closed issue #3039:
URL: https://github.com/apache/apisix/issues/3039


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org