fix if not set the time_zone the seahub will start error.

This commit is contained in:
Hulk 2019-06-11 17:27:04 +08:00
parent 709ed6219a
commit fe7016a77b

View file

@ -154,7 +154,7 @@ def init_seafile_server():
}
COMPRESS_CACHE_BACKEND = 'locmem'""")
fp.write('\n')
fp.write("TIME_ZONE = '{time_zone}'".format(time_zone=os.getenv('TIME_ZONE')))
fp.write("TIME_ZONE = '{time_zone}'".format(time_zone=os.getenv('TIME_ZONE',default='Etc/UTC')))
fp.write('\n')
fp.write('FILE_SERVER_ROOT = "{proto}://{domain}/seafhttp"'.format(proto=proto, domain=domain))
fp.write('\n')