官术网_书友最值得收藏!

Timestamps

Timestamps are also available for the log output, although not by default. You can get the log messages prefixed by a timestamp by adding the --timestamps option. For example:

kubectl logs deployment/flask --timestamps

You then may see the following:

2017-09-16T03:54:20.851827407Z  * Running on http://0.0.0.0:5000/ (Press CTRL+C to quit)
2017-09-16T03:54:20.852424207Z * Restarting with stat
2017-09-16T03:54:21.163624707Z * Debugger is active!
2017-09-16T03:54:21.165358607Z * Debugger PIN: 996-805-904

It is worthwhile to note that the timestamps are from the hosts that are running the containers, not your local machine, so the time zone on those logs will often not be the same time zone in which you reside. The timestamps all include full-time zone detail (typically set to the UTC-0 time zone) so the values can be converted easily.

主站蜘蛛池模板: 尼木县| 漳浦县| SHOW| 晋州市| 平谷区| 建湖县| 辉南县| 介休市| 璧山县| 东城区| 黎城县| 平塘县| 宽甸| 勃利县| 天台县| 库车县| 太保市| 房山区| 高碑店市| 贡觉县| 宜良县| 高邮市| 密云县| 子长县| 大丰市| 新绛县| 台山市| 宜章县| 临江市| 太保市| 淳安县| 金沙县| 岫岩| 镇江市| 平遥县| 肥东县| 合山市| 阳泉市| 望奎县| 金坛市| 泰安市|